From 0af6fc8c5f024ed404b4a7e535306f5644452f0e Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 11 Jun 2024 23:56:42 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20post-p?= =?UTF-8?q?rocessor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- .../V1/Gapic/NetworkServicesGapicClient.php | 2 +- .../Cloud/Networkservices/V1/Common.php | Bin 1930 -> 0 bytes .../Google/Cloud/Networkservices/V1/Dep.php | Bin 9040 -> 0 bytes .../Networkservices/V1/EndpointPolicy.php | Bin 3659 -> 0 bytes .../Cloud/Networkservices/V1/Gateway.php | Bin 2567 -> 0 bytes .../Cloud/Networkservices/V1/GrpcRoute.php | Bin 4529 -> 0 bytes .../Cloud/Networkservices/V1/HttpRoute.php | Bin 6027 -> 0 bytes .../Google/Cloud/Networkservices/V1/Mesh.php | 64 - .../Networkservices/V1/NetworkServices.php | 110 - .../Networkservices/V1/ServiceBinding.php | 59 - .../Cloud/Networkservices/V1/TcpRoute.php | 85 - .../Cloud/Networkservices/V1/TlsRoute.php | 78 - .../V1/CreateEndpointPolicyRequest.php | 153 - .../V1/CreateGatewayRequest.php | 149 - .../V1/CreateGrpcRouteRequest.php | 149 - .../V1/CreateHttpRouteRequest.php | 149 - .../V1/CreateLbRouteExtensionRequest.php | 227 - .../V1/CreateLbTrafficExtensionRequest.php | 227 - .../NetworkServices/V1/CreateMeshRequest.php | 149 - .../V1/CreateServiceBindingRequest.php | 149 - .../V1/CreateTcpRouteRequest.php | 149 - .../V1/CreateTlsRouteRequest.php | 149 - .../V1/DeleteEndpointPolicyRequest.php | 71 - .../V1/DeleteGatewayRequest.php | 71 - .../V1/DeleteGrpcRouteRequest.php | 71 - .../V1/DeleteHttpRouteRequest.php | 71 - .../V1/DeleteLbRouteExtensionRequest.php | 149 - .../V1/DeleteLbTrafficExtensionRequest.php | 149 - .../NetworkServices/V1/DeleteMeshRequest.php | 71 - .../V1/DeleteServiceBindingRequest.php | 71 - .../V1/DeleteTcpRouteRequest.php | 71 - .../V1/DeleteTlsRouteRequest.php | 71 - .../NetworkServices/V1/EndpointMatcher.php | 76 - .../EndpointMatcher/MetadataLabelMatcher.php | 196 - .../MetadataLabelMatchCriteria.php | 66 - .../MetadataLabelMatcher/MetadataLabels.php | 108 - .../NetworkServices/V1/EndpointPolicy.php | 526 -- .../V1/EndpointPolicy/EndpointPolicyType.php | 64 - .../Cloud/NetworkServices/V1/EventType.php | 95 - .../NetworkServices/V1/ExtensionChain.php | 182 - .../V1/ExtensionChain/Extension.php | 416 -- .../V1/ExtensionChain/MatchCondition.php | 82 - .../Cloud/NetworkServices/V1/Gateway.php | 444 -- .../Cloud/NetworkServices/V1/Gateway/Type.php | 68 - .../V1/GetEndpointPolicyRequest.php | 71 - .../NetworkServices/V1/GetGatewayRequest.php | 71 - .../V1/GetGrpcRouteRequest.php | 71 - .../V1/GetHttpRouteRequest.php | 71 - .../V1/GetLbRouteExtensionRequest.php | 75 - .../V1/GetLbTrafficExtensionRequest.php | 75 - .../NetworkServices/V1/GetMeshRequest.php | 71 - .../V1/GetServiceBindingRequest.php | 71 - .../NetworkServices/V1/GetTcpRouteRequest.php | 71 - .../NetworkServices/V1/GetTlsRouteRequest.php | 71 - .../Cloud/NetworkServices/V1/GrpcRoute.php | 534 -- .../V1/GrpcRoute/Destination.php | 165 - .../V1/GrpcRoute/FaultInjectionPolicy.php | 129 - .../GrpcRoute/FaultInjectionPolicy/Abort.php | 133 - .../GrpcRoute/FaultInjectionPolicy/Delay.php | 129 - .../V1/GrpcRoute/HeaderMatch.php | 142 - .../V1/GrpcRoute/HeaderMatch/Type.php | 65 - .../V1/GrpcRoute/MethodMatch.php | 202 - .../V1/GrpcRoute/MethodMatch/Type.php | 65 - .../V1/GrpcRoute/RetryPolicy.php | 168 - .../V1/GrpcRoute/RouteAction.php | 250 - .../V1/GrpcRoute/RouteMatch.php | 119 - .../V1/GrpcRoute/RouteRule.php | 130 - .../Cloud/NetworkServices/V1/HttpRoute.php | 518 -- .../V1/HttpRoute/CorsPolicy.php | 344 -- .../V1/HttpRoute/Destination.php | 144 - .../V1/HttpRoute/FaultInjectionPolicy.php | 129 - .../HttpRoute/FaultInjectionPolicy/Abort.php | 113 - .../HttpRoute/FaultInjectionPolicy/Delay.php | 119 - .../V1/HttpRoute/HeaderMatch.php | 330 -- .../V1/HttpRoute/HeaderMatch/IntegerRange.php | 104 - .../V1/HttpRoute/HeaderModifier.php | 147 - .../V1/HttpRoute/QueryParameterMatch.php | 202 - .../NetworkServices/V1/HttpRoute/Redirect.php | 330 -- .../V1/HttpRoute/Redirect/ResponseCode.php | 85 - .../V1/HttpRoute/RequestMirrorPolicy.php | 87 - .../V1/HttpRoute/RetryPolicy.php | 216 - .../V1/HttpRoute/RouteAction.php | 546 -- .../V1/HttpRoute/RouteMatch.php | 290 -- .../V1/HttpRoute/RouteRule.php | 139 - .../V1/HttpRoute/URLRewrite.php | 113 - .../NetworkServices/V1/LbRouteExtension.php | 462 -- .../NetworkServices/V1/LbTrafficExtension.php | 460 -- .../V1/ListEndpointPoliciesRequest.php | 151 - .../V1/ListEndpointPoliciesResponse.php | 109 - .../V1/ListGatewaysRequest.php | 147 - .../V1/ListGatewaysResponse.php | 109 - .../V1/ListGrpcRoutesRequest.php | 147 - .../V1/ListGrpcRoutesResponse.php | 109 - .../V1/ListHttpRoutesRequest.php | 147 - .../V1/ListHttpRoutesResponse.php | 109 - .../V1/ListLbRouteExtensionsRequest.php | 215 - .../V1/ListLbRouteExtensionsResponse.php | 135 - .../V1/ListLbTrafficExtensionsRequest.php | 215 - .../V1/ListLbTrafficExtensionsResponse.php | 135 - .../NetworkServices/V1/ListMeshesRequest.php | 147 - .../NetworkServices/V1/ListMeshesResponse.php | 109 - .../V1/ListServiceBindingsRequest.php | 147 - .../V1/ListServiceBindingsResponse.php | 109 - .../V1/ListTcpRoutesRequest.php | 147 - .../V1/ListTcpRoutesResponse.php | 109 - .../V1/ListTlsRoutesRequest.php | 147 - .../V1/ListTlsRoutesResponse.php | 109 - .../V1/LoadBalancingScheme.php | 65 - .../Google/Cloud/NetworkServices/V1/Mesh.php | 321 -- .../NetworkServices/V1/OperationMetadata.php | 307 -- .../NetworkServices/V1/ServiceBinding.php | 270 - .../Cloud/NetworkServices/V1/TcpRoute.php | 404 -- .../V1/TcpRoute/RouteAction.php | 120 - .../V1/TcpRoute/RouteDestination.php | 144 - .../V1/TcpRoute/RouteMatch.php | 139 - .../NetworkServices/V1/TcpRoute/RouteRule.php | 127 - .../Cloud/NetworkServices/V1/TlsRoute.php | 370 -- .../V1/TlsRoute/RouteAction.php | 74 - .../V1/TlsRoute/RouteDestination.php | 116 - .../V1/TlsRoute/RouteMatch.php | 147 - .../NetworkServices/V1/TlsRoute/RouteRule.php | 119 - .../V1/TrafficPortSelector.php | 79 - .../V1/UpdateEndpointPolicyRequest.php | 137 - .../V1/UpdateGatewayRequest.php | 137 - .../V1/UpdateGrpcRouteRequest.php | 137 - .../V1/UpdateHttpRouteRequest.php | 137 - .../V1/UpdateLbRouteExtensionRequest.php | 211 - .../V1/UpdateLbTrafficExtensionRequest.php | 211 - .../NetworkServices/V1/UpdateMeshRequest.php | 137 - .../V1/UpdateTcpRouteRequest.php | 137 - .../V1/UpdateTlsRouteRequest.php | 137 - .../create_lb_route_extension.php | 175 - .../create_lb_traffic_extension.php | 176 - .../delete_lb_route_extension.php | 81 - .../delete_lb_traffic_extension.php | 81 - .../V1/DepServiceClient/get_iam_policy.php | 67 - .../get_lb_route_extension.php | 72 - .../get_lb_traffic_extension.php | 72 - .../V1/DepServiceClient/get_location.php | 53 - .../list_lb_route_extensions.php | 73 - .../list_lb_traffic_extensions.php | 73 - .../V1/DepServiceClient/list_locations.php | 58 - .../V1/DepServiceClient/set_iam_policy.php | 73 - .../DepServiceClient/test_iam_permissions.php | 80 - .../update_lb_route_extension.php | 160 - .../update_lb_traffic_extension.php | 160 - .../create_endpoint_policy.php | 110 - .../NetworkServicesClient/create_gateway.php | 115 - .../create_grpc_route.php | 138 - .../create_http_route.php | 127 - .../V1/NetworkServicesClient/create_mesh.php | 88 - .../create_service_binding.php | 105 - .../create_tcp_route.php | 98 - .../create_tls_route.php | 119 - .../delete_endpoint_policy.php | 80 - .../NetworkServicesClient/delete_gateway.php | 76 - .../delete_grpc_route.php | 76 - .../delete_http_route.php | 76 - .../V1/NetworkServicesClient/delete_mesh.php | 76 - .../delete_service_binding.php | 80 - .../delete_tcp_route.php | 76 - .../delete_tls_route.php | 76 - .../get_endpoint_policy.php | 71 - .../V1/NetworkServicesClient/get_gateway.php | 67 - .../NetworkServicesClient/get_grpc_route.php | 67 - .../NetworkServicesClient/get_http_route.php | 67 - .../NetworkServicesClient/get_iam_policy.php | 67 - .../V1/NetworkServicesClient/get_location.php | 53 - .../V1/NetworkServicesClient/get_mesh.php | 67 - .../get_service_binding.php | 71 - .../NetworkServicesClient/get_tcp_route.php | 67 - .../NetworkServicesClient/get_tls_route.php | 67 - .../list_endpoint_policies.php | 72 - .../NetworkServicesClient/list_gateways.php | 72 - .../list_grpc_routes.php | 72 - .../list_http_routes.php | 72 - .../NetworkServicesClient/list_locations.php | 58 - .../V1/NetworkServicesClient/list_meshes.php | 72 - .../list_service_bindings.php | 72 - .../NetworkServicesClient/list_tcp_routes.php | 72 - .../NetworkServicesClient/list_tls_routes.php | 72 - .../NetworkServicesClient/set_iam_policy.php | 73 - .../test_iam_permissions.php | 80 - .../update_endpoint_policy.php | 90 - .../NetworkServicesClient/update_gateway.php | 101 - .../update_grpc_route.php | 123 - .../update_http_route.php | 112 - .../V1/NetworkServicesClient/update_mesh.php | 82 - .../update_tcp_route.php | 89 - .../update_tls_route.php | 106 - .../v1/src/V1/DepServiceClient.php | 34 - .../v1/src/V1/Gapic/DepServiceGapicClient.php | 1454 ------ .../V1/Gapic/NetworkServicesGapicClient.php | 3503 ------------- .../v1/src/V1/NetworkServicesClient.php | 34 - .../v1/src/V1/gapic_metadata.json | 322 -- .../resources/dep_service_client_config.json | 107 - .../dep_service_descriptor_config.php | 131 - .../dep_service_rest_client_config.php | 349 -- .../network_services_client_config.json | 252 - .../network_services_descriptor_config.php | 361 -- .../network_services_rest_client_config.php | 702 --- .../v1/tests/Unit/V1/DepServiceClientTest.php | 1442 ------ .../Unit/V1/NetworkServicesClientTest.php | 4472 ----------------- 203 files changed, 1 insertion(+), 38285 deletions(-) delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Common.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Dep.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/EndpointPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/GrpcRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/HttpRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/NetworkServices.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/ServiceBinding.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TcpRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TlsRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateEndpointPolicyRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGatewayRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGrpcRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateHttpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbRouteExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbTrafficExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateMeshRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateServiceBindingRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTcpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTlsRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteEndpointPolicyRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGatewayRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGrpcRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteHttpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbRouteExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbTrafficExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteMeshRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteServiceBindingRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTcpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTlsRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabelMatchCriteria.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabels.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy/EndpointPolicyType.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EventType.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/Extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/MatchCondition.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway/Type.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetEndpointPolicyRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGatewayRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGrpcRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetHttpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbRouteExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbTrafficExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetMeshRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetServiceBindingRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTcpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTlsRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/Destination.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Abort.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Delay.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch/Type.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch/Type.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RetryPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteAction.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteRule.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/CorsPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Destination.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Abort.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Delay.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch/IntegerRange.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderModifier.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/QueryParameterMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect/ResponseCode.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RequestMirrorPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RetryPolicy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteAction.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteRule.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/URLRewrite.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbRouteExtension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbTrafficExtension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesResponse.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LoadBalancingScheme.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ServiceBinding.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteAction.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteDestination.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteRule.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteAction.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteDestination.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteMatch.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteRule.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TrafficPortSelector.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateEndpointPolicyRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGatewayRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGrpcRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateHttpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbRouteExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbTrafficExtensionRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateMeshRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTcpRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTlsRouteRequest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_route_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_traffic_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_route_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_traffic_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_route_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_traffic_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_location.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_route_extensions.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_traffic_extensions.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_locations.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_route_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_traffic_extension.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_endpoint_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_grpc_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_http_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_service_binding.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tcp_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tls_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_endpoint_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_grpc_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_http_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_service_binding.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tcp_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tls_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_endpoint_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_grpc_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_http_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_iam_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_location.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_service_binding.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tcp_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tls_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_endpoint_policies.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_gateways.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_grpc_routes.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_http_routes.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_locations.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_meshes.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_service_bindings.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tcp_routes.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tls_routes.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/set_iam_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_endpoint_policy.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_gateway.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_grpc_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_http_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_mesh.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tcp_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tls_route.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/DepServiceClient.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/Gapic/DepServiceGapicClient.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/Gapic/NetworkServicesGapicClient.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/NetworkServicesClient.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_client_config.json delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_descriptor_config.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_rest_client_config.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_client_config.json delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_descriptor_config.php delete mode 100644 owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_rest_client_config.php delete mode 100644 owl-bot-staging/NetworkServices/v1/tests/Unit/V1/DepServiceClientTest.php delete mode 100644 owl-bot-staging/NetworkServices/v1/tests/Unit/V1/NetworkServicesClientTest.php diff --git a/NetworkServices/src/V1/Gapic/NetworkServicesGapicClient.php b/NetworkServices/src/V1/Gapic/NetworkServicesGapicClient.php index e83fc3cccad3..62d0585f837e 100644 --- a/NetworkServices/src/V1/Gapic/NetworkServicesGapicClient.php +++ b/NetworkServices/src/V1/Gapic/NetworkServicesGapicClient.php @@ -105,7 +105,7 @@ use Google\Protobuf\FieldMask; /** - * Service Description: + * Service Description: Service describing handlers for resources. * * This class provides the ability to make remote calls to the backing service through method * calls that map to API methods. Sample code to get started: diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Common.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Common.php deleted file mode 100644 index ced22555a28e0bda23dd6e53811e2908d4937469..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1930 zcmcIl+iu%N5RD|qiC3-TFhL@yD6*9UL8zeCpyz5FsBAY2?s=3QBzXlgwuqPl+FabiHajjRRLu7U0C;FmR!{ zg;UJL_F>3m{<}D5HBL$*%V7@!0X!hS-Gj*GG!%@FrKw@eKoo^czBIS8un8QU;%3Ux zFs_i?#e&ChK03x6M9hO7#XA8wE&ka{YG#Ji-lO1q9XKHi%D7>iWpxI!%(Y0&qOvK1 z%){lrsvu9kqgnc<=M~xRNo_O>ehJ%0==~ac{BJ~|JxHx}B_aKig!Dzbo*A^1hGZvN zA}5^6s_{!1-98KxCCjens?wgJs>?yD+ez$eC0uG&x9fTqEeF$!>^qge%!<}VHzDv+ zm-0Vzxr0^(;Zg;)igZ{@ac-lP1@K92;HwyR07P@0`GM!R)%(yrLA6%(VO+(j1`5wva zD=D*5nFlN}uq;hq53X6W8LyN!-dCg3~s^du`=KQG(onxtPs)blnB6SOSM z^K13rE9maBBkk7``g$1!M_x5~?t=DZIl6U`NK`A!>Q%R`{~>f# z@1pe!1&Or#2&Fwprlm?-X{xNr_NNC6;>RFaWoj!oD5_roQ3WqDdV;n_eaq~bmgx-5 zPJif(Oso6c>Ao0P{TBn%`QhMb-0u$d2L0Z~HSJ5ZmY$mjFE>i(UWdbta%UZVk!iyb z??UK&ETK&~@1Lgp-{sUw$h;*jGzL zS4%|CmdH`Ii1g$3AGw8{?U{Vh16vi+Vj$vE^GK}N)WL3?Mr;m!k_c$Hn S=cfK=C%&>w=kh5!Md%Y%t$Vuw diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Dep.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Dep.php deleted file mode 100644 index 42c11411c28f82972ec10af861f1f0e4e725d52b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9040 zcmeHN&2QVt6))x3vB%v+nS5C5O=7N+MI0lMU}cLm%6hl7r8q`q*_9Pzw-8ED)W~K- zlU$Or*A0AVfue`)t>>Ql1#D5EK)dKa&_m%KT67N!!2I*DzS*G`J^G&4`qLs$c}6Kwr-npz13_ISJv%4 z$1sVTk>$dMT;8b4#ll+kbujhpmaCJzykpxtCduli-D+el;vd-VQ;)d&hEBZf{$jR4 zoJ`;qAxqmMo}=kRUfonqpZtMZvbbeEuY+6BoS%Lb0E7mI2u_THXt4L*Izwszc>Wf|5^ZNs5SG91VucM2_L zJNVS0DQtRi&+!jOFb(!(tGP z@WR|z5F%m?UTRDp1IG`BbsWwU_?*3q&UH?OUqk0~Vyff=2R5CC+ZN&Mza=ykdWeJI z3YyYd{;usB{$UV%0F8t%p|iYn!oowq)=<)GIgaf@omR;{FxN|+fw<1)7W&6UhgT0B zLIaU-7M-P=X1Dy*cmVmU!h_hTBXo*gO_l+XHx=X30KjCsnv|v#-+i%WOB~xB}CEo#?)oea8Pf z%9^&$%60ac_!Ay>@exeSy6Q8QLMn6NI$F3GGd732AEtjJq3b2X^SjsORml4-D28|q zO*onhNyr7_0qoPilzVuDP$3r`ZHK5Hw7Ef=j5CtWAQU|J?Wd5Wp>Rm}BARF#CbX^~ z7hFvwd>KvJE+nj4KMXX0r|b_TG}ki}&w&P$;0n+y1~3moqbhq(Fk*<5!87Q*1<SdT!f^oI#Fw-TsQ_uh)hPH}5* zqM0~kRiklI9ujyPU5XnOZ24&Lv*eyb$Ype;6Edz$L%I0#cYpWkWMWcE{~pNkBv9Ml zXq*T#Z72e^#|d)Sm@@A63W+rYqcAEiB$g8$A$?staw|6&P;tRM-7EtVfavHY=wqL(dv2il5d zC*Zg|c&Y5PWQEeD>})TS7t9D_y<9T-DE(^*U1fD8;!~*TYNSBk4+`WW9y+}LYI*#= zgs$}ngBQm#g0?}8fFw%e;?U_aWMS0NY)}|GK^7PnJCuYYJT!sQ-%OxuqA12sbZVQK z4qA-}nvrr?LC}*$5$DBlc);W8MocL@1|o=37>~hdg)lxCRt8Ten3y8?9SBAg!T4ZK zhdF%<;KC2-ky)Ho@hrMh+%A@@YW2O%qWYw~wOL$Qd$d+8BtHjz;rUAOD^H4BRrPUE zDHJPPNeL&>=f%V2jlz4$1QgF?rMR`ZQQj(sJU5oUGzn7_q?V8xYw#&mzcx#>hSUOf}w_>kkE`+1R?=jDn zdu-e8#GN%_AA&9i0Bxj4-S&L!!3KW}unDmp0k&SI1H$&J;b4D!mLMb8aBLLUSbU@&|V`Twd=6AV}{K1cCnc$}k97nje6kA{n8XgGz zM-YzK4s8J8h_w^J_P>?xVa~M?G^AY{@8d5Frj4Bi*~7n;(8ZV@4?h&i-}Blf#!3V? zd~1;|v}>Y>=H(j}2_*}P_@e~6B4n-eHSQ01yrGDxj~f0I()x{<<8~Y~vnNvMb{>DI z5Jnye8T@j3v>ndJw6pjpfRoU%p>c{g91y3U4T013ZZz&hmG5i0$3poc!1d9+&agdT zPb^X|By>dxSEtDUjEXlL5UKY^*1P))j4H#X&urybx&HFY@;@k94Y+0RCnw93(3fsfRo|4py3RyL{B8$#^gDL+EpiT&Mo9>&Zunxz*rnkjx7G8YEL@UxV-_*vo7$9*Yq*{=ta&VnmFo!6zdx5^3fp spAY=x^ASh+{PtpfBB)IFZiPQP-(jC*w0*(R^XrXZB>T$Z2pu8xAC@>P!2kdN diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/EndpointPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/EndpointPolicy.php deleted file mode 100644 index 6d16490baf6516f855ead7843eadb90caae3c517..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3659 zcmb_fO>g5=6eVdpkQX{_4I@GasgF#h=}1#&S~>{16qK(<88wL~O{*!2upH;5HFa!b zzZ5c6V1dK}_!TVqDXiJBW8I%HE3V(O-8f0rq?&GOIrrndbMHI%`pd8FGaEg^C1Mgs zrKF8peN4{?wjGOFnq}ZtuhSt8)~v3r8^jSYF4SnE8h=flq>(n3_ z&9Hjyj7jJZmUHeB=R((ro4MG^5VLJtx=9t=GIXskvJ42BYL~dSsu5h0a}`3>wo27z zi3MxsySjmA;xVxJyWB)Wn#~vW@=>P3Fa|9+jZLlLiTWgPWCtgewt;I630}HW`VexqubPS zWH6PaQ$j;#y*C?A{Ip&;y@NM6MoAh2xreFKBg5G-b_ne`<}SnS1sH@+%?aFPZN0g# z6Qi9YXX=G+Ig)gJs_P&(xz>qa*r~m4DpoUZb-R{1efp4B2EU@Z=XdaJ=+IYG?b?%l zSuHoef_`L`%eLELq4uHAH$rMXq93DwAE4)VYH(qVyNT>xh$Htxyx3a(*pI8)ddBfd z=a*yk>1`?DRsyrWb#MdO#e%lXbiC>-UEt5R@Udh<3mTBb4bp$ShwewOl(2&4y(^lE z;n+qZH}_vQF6^MB<`7T|#q&?a;g{t0s^}jy2rh;d@Vw?cubvH;+xMEA&Pzu347EiJ zH#LvvAkA)&<|aPHD1PyPc^6IU^gSFg;RwyszD-gK0O0<1Zq|6w@C}H>NqL1nRD1Ny za`e|AJC^CoTZqNLt^r7gDlRdI2AY*ZEb7j!Q5)P_2IoWHmvfs!$+jUUXI8(?x^AAI= zZldH+zX(Y*cTW1e^@T;WaG@GK-tP%1{zWYPEfU7tL0Ct)SS`r4aQhP{c^Fe{0`i!#lv!;n9tS~xn6s9vK$kZP_k5)^U7hdeq5|C$EBaHvX^Kx zY#BaFM_VR}KzIT7?>i``o4NF#1{uTBSWm*c;BgSnW5%WqGx{>@GMi1)LHhR?dU&9_ zG?D^L>*V_$h^tUU_iWXH3i#^q9Ms`WHY3akc?BhG^^_p-(2Gac#?ViSPogM2`Sa0huQonOl20a>l;!5n3|IkFczGz&Hv|=MrfJrAj2q zNI&2sAJIymjTsA={s&0UGkJ|d3X;4f($|m>C9ALKZN|Q@@)fi+V!-M!JC{s!(tpCS zj+p*WKGyYk@CFuZs7XU5TnV_~OaRHp(X0jMAY15R0R)Yb$r#^8eRIDqphqC}w>4z$ zgD3{sTQ=p`Hx)kkf~^8(#;G;7Zo@o*jeA5m?AGqso4?{~CAMmdYAMg2kUrX(}aEeDxT(HB#Fh5q>(_91V-84Vs{#VjcFw~Xm5KINYsLtiO3 PexWc+{v9zu1BCtu@jv!t diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Gateway.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/Gateway.php deleted file mode 100644 index 47966104bb94cfe9dd1bbd42fb30280ea9bcfbfc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2567 zcmbtW!EW0|5Upg%iAHs6vu>mM&}@~UQGl9)(;Nyqb}PxWY9N+XTXv8_06|eJnH5d4 z+?7)`)gSardg*`kD|!wP^xjivmrKT$ZA3wI5wV$}{wJ@+@f(H0rl9;4`c)pjuU9qtA` z5e^5wLn{wSj45pIhXFFMMUu4If)pgAyXSKn`L@^Hq0EWgkOxs4O$}p6c}k@?sXSC+ z1)Mt|l{iPkxRT@+;nA30j7~^I`8e`7W!?f{nm%=}A*~j=-CdV@{W?9h&)pz0j5oJ> z19Fq=Ayt)}+bg9*M%}mBX#R+)Z^uO)aQiI0-dC1jecM%p*ZTdG-(A#WC1phL^8j8i z!TLK1QM((P>r%J+jBfSwjkV7eo*lZ?NO2U4crDSqlr-w1IuP_*XUK%IQ0Udvf+yFF z4a)!K;Fc1zwgNfP6{QTxR0{Qle`;CnGbk|X4J^;~N2R6Yd_j8*MJJ-z1eO3SW${h% z(VDLAl0?%}as`_78i&|t%4=ahuRU1w>>l-4DMuDC%;O}?O_b^CLi$tbX8Jsuhy*fP z35tEyG1zpad~%_T_C4hIB&4N9Jo@O-`rIKp=p?Z7ng;nWh&U@1G0S{R-=~mgPJpnt zWu!%Mt%RN{{I{fvbs946N|a)Zwi9Qaw$pUf|&P3w%6F9;eCB#j{~N zF{kC<;ghE>;|hu$(qG2dfZ8@JhIT}KuH>g9SO3*2+Po>PKq0h;)M7Yur5;5^Kpyd6 zME#ObTcJFH)yvUYh$&OefZHlVh6xCnRp!-zb_YK8>95?n5KJ^gq5LDPG;tuuH%~75 zGd)&eo(ut?e+;xi6>A>m^^(dz^*}PX->aR0!4;$odlBs{FqPE4C zyq)=JKb~R9Hvn5~7+hIiu>Ej0<{Tq7et*0J(?Wuo2&pqeTdrp13D+%#6u?rVG+I_!$@Ap1;AI&>m2X4r9 zVi8xRM3;AZGVK!CacydAwkhxU?KW{`&E9hilek4$Ufht^H@4*3;>y;?DC*h1tC6zY zvF(mYN}6f=ddVX6rS0x|#N9VE;+6JiN*&kH6xa4CDROWCOWh-$qiRI1H>zuds=7+m zR-NOt78p)z{U}cB*~}b(W~!bi*AcJD;NUgL_~-aLrlH9mRVn_vX?TiZ8Prfs<9jsg zvD{WokD&C)y=~vps9{?&6WFjcQn(`vOt$x?VRO)*Hmx!f5>hb7(`Uv zb557#-n;k22z*u1^~g0#7|(@>Oh)Z(`1?b+KWHFJ*M&rphko%`=oj~Aa@PV#)iFwL zz_3Vy+(*F@PYH~wk{-|)tcPh8t+$zTl|3XY*b$swigwVD5wRiv<7G%k$s%2XVU~B< zgq$d(t3&@(lF~G!Jz};M)3A24ZkS z!AuUMhWe9w3L~bvLrgC_EDzx^Uxde;MQSlJskq7oYZi5TOofD$g^V8LBnD(Q6`GV_ zrgm+Q^2(DP!IJ_C=3oTFs7t(Tnt%KhVcu14!HwhI6vm??y&{&x(i#d$U%^-h?R}~C zyex3>A{Q^fC+`uj3o&UKQm${}>7(5EhXWYTOJEa)xi52Xl90ht+O_pHm1Lxof`l+hEm)@2tn;N80UpNsO&r_0uGUNzO=`W&oajcD>6)Ksz(%$SRR(-eS%I- z6vjB>@`X2vM1CHI*%{ImnA&>Ls43g)n~mDS%F;@0aq5DUhE(l&WnpWIIZ$fW>f5W8 zrc!&}Xx272S2otClGRIaQ8{`>?#~2dmWiqp_q21*CLhs=a{I+5l;C8eVac zf$_*@(CUuu3SBd^=Z3B@uw`a#jzWqbBt3vk+jvEEC2qvE(1@r|haFldb``)OIJsF= z?TF%@;;_|87*}F&)d|QbhdXm<5Z8fK*)FAy!loJDDAtXoaw{=#y|lc&PnEqx8+ zu>cXGgXK^xpn2d)I!w1&OyRg01eN0OsNz*1Gdmypp^r{>S}=)IN-)ZrFwVQ!BUm3k z+r2^nEfqus%8YTTLE37Jb`F{QB?0NE-AGSibdR+d#zhqn!B9`lJg+AF;d zejSudTjM1TzlA>!_=Sh-hF^JOblGj?Apb)GK3Fw88VxXBlYHl6*}_3$#8F+$NS;jT z>U~}s?@IkEcL~xCrnBPVrAJgpNy0p5pQw#hRCK1i3)9Cn@ElAfBFzU)oa-8T_HO^4 zm9D}?i@c&r>`YE|ej6^=@nRJ67~1^g$UGWY+`l{We8Ms>WFJ_o=P-?p zg-~)rsdIX(`fmbmV4HtmJXI&7lN;>1-AH`1Cdy}U`Czkm$3F4QfO9#%G#pE1XJ_uj zmtT|D>-?RexWL{SitFN?A(%0|;*v diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/HttpRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/HttpRoute.php deleted file mode 100644 index 0953f461d643b9f753622093ef5e65d24de80fb5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6027 zcmb_g&2!t<5f3R-78kNCL$*w@ZGy^4t*8xYF=?lzYbz8|h|^kwgUn z=mV&aW;E03q5nWyZhVS zx4&NY`#wC-)`&}}5fV$=JJG^E(R}KKp6NN--k{qhR5QH;-*yNsXj-kIZ8zFly|&T* zF^UG>fSRPN^*pcVkfP~$1FPtg@W`Y40ilPsNrK|xQn4R~zD~VCND3Srz%>p?;2S2< z)|x9@Bs44|G&*Y>r&DD(o$a$Yo##uB0ZhjT0&N}fS_}?80S*88gFVMKwIDP?{O@f$ z&~4WaZNstujMsXibqyyVD1C8nci@_#?YSBgXt*X>cvlmcZ13B?hh})9MT#|>vq9x5Jzelu+zjv8)^#e4P+#ydd#yi5uB4We* zf8T^`OcwPH++e)RrL@#Sc4h4AN?M(TY(Si@?%3{rPKnmX)Ep?53~lslE**VIsULu1 zQiAzHXNTp+@QYH)7o;5`O$xDZ*g0cNYTzTsrPPh&I1b8$eQ8q8U*Ul> zF5@i4^(#C)1B%^qJxX-b2uO}=rLMtEVbOpSELkv*cuM^Urq5k23hAc_e1D1cnTwiu zd2Wup4hq)X&~|yjK{8LuMnfM-ZHq4}ormxaYg|~*aV`t280J0(z>a88SWF!eyVnmz zMCAWA1`{n}*_4c`osqN{@t`x2eI1XBwJAiIn2Ays0f88tKW z|46~)8PFfWT&up*Y;5n;^=hM5*LSyfn)T|&>PEdb{f3I4w;IpuHN9DHZB@4G+wIMd z^;&(kvb))yPN`YQtTuMHYtw1uU3RBl*BkBidTV+Nl~vpIt!ATDX??7>u!n5btL^C< zY(0h=u4nT9NyFV$W8j1v?jO+?ScjS(ws|LN8!{Ggj1%q*rBqK~#>?;uH3r5|jXksv z4}<>$YK4L2pFu{z7eK*WNi2O-^|?s(xNb(Rl&S*w1iNcDGU zgFxoB%OpNc!<1yHXW7_5P_+SL0b#k2m9CXYfoqhmvp9tv67n*}01b=f)7J#V22B7W zBPluX4jFy0=3_peh!4Z$y-$Savn;V68qPqNCtFVcGR5}BIIr5f46xhUYzeBWKY$s| z>2nO`$(9uwnFj=~Ip6a>C@q4OT*hS%rmn2Qw{#qz=L@n^N}b;EZ_2+qEbwN?s&sOGa{P{>v0V z)uVyL#HP#;iqg5N!)%x3IDE0nB&Yk_ zr@THZrR4;mmnAp#1>C11Vx)2P1DOf1;4`&c>-lexV;EBBZ{%uP)b)*jD?9{vGhZh3nU@aXioS8+>6YAz!@947dUK^ z-sm#oqmfLcY6Qw&a7rnOk%mOif0lx5{G?D<8TatrfRq-cA_?k9|GEm}_y&m{k;(Wr z!ruIQpp3koSQG!h>Ok53rm_zUuXxbK&oXrx3ozqfQ2a#xIxRY$$(u}Ei+-N+Q5IJV zS9uAhEW@16|0MRDI zJ3l=$X^=O*zB}f>NWpBCPZ?r+M$oTs&OG+?@jz0y#Y<4mL#hD7Z?YUGFcg1?&;K2@ z-{sSe3)&CoAZ&~y3-!h6Njw!3GlH{PiE5KrtB+t7J5hYpUQp^ay|waf3LfBF>s9fz zG8LcPWP{XZ>cy65JLT|*jc9t_g#j{-Z*Ycuj>`Vt;|nYQOux0pC&+~=n;;jq#ROSC z^n$|krLUqL9XVuNzV(Ia+%|l%jbZ~<>yO#internalAddGeneratedFile( - ' - -*google/cloud/networkservices/v1/mesh.protogoogle.cloud.networkservices.v1google/api/resource.proto google/protobuf/field_mask.protogoogle/protobuf/timestamp.proto" -Mesh -name ( BA - self_link ( BA4 - create_time ( 2.google.protobuf.TimestampBA4 - update_time ( 2.google.protobuf.TimestampBAF -labels ( 21.google.cloud.networkservices.v1.Mesh.LabelsEntryBA - description ( BA -interception_port (BA- - LabelsEntry -key (  -value ( :8:_A\\ -#networkservices.googleapis.com/Mesh5projects/{project}/locations/{location}/meshes/{mesh}"w -ListMeshesRequest; -parent ( B+AA%#networkservices.googleapis.com/Mesh - page_size ( - -page_token ( "d -ListMeshesResponse5 -meshes ( 2%.google.cloud.networkservices.v1.Mesh -next_page_token ( "K -GetMeshRequest9 -name ( B+AA% -#networkservices.googleapis.com/Mesh" -CreateMeshRequest; -parent ( B+AA%#networkservices.googleapis.com/Mesh -mesh_id ( BA8 -mesh ( 2%.google.cloud.networkservices.v1.MeshBA" -UpdateMeshRequest4 - update_mask ( 2.google.protobuf.FieldMaskBA8 -mesh ( 2%.google.cloud.networkservices.v1.MeshBA"N -DeleteMeshRequest9 -name ( B+AA% -#networkservices.googleapis.com/MeshB -#com.google.cloud.networkservices.v1B MeshProtoPZMcloud.google.com/go/networkservices/apiv1/networkservicespb;networkservicespbGoogle.Cloud.NetworkServices.V1Google\\Cloud\\NetworkServices\\V1"Google::Cloud::NetworkServices::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/NetworkServices.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/NetworkServices.php deleted file mode 100644 index 40934b680b86..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/NetworkServices.php +++ /dev/null @@ -1,110 +0,0 @@ -internalAddGeneratedFile( - ' -N -6google/cloud/networkservices/v1/network_services.protogoogle.cloud.networkservices.v1google/api/client.proto5google/cloud/networkservices/v1/endpoint_policy.proto-google/cloud/networkservices/v1/gateway.proto0google/cloud/networkservices/v1/grpc_route.proto0google/cloud/networkservices/v1/http_route.proto*google/cloud/networkservices/v1/mesh.proto5google/cloud/networkservices/v1/service_binding.proto/google/cloud/networkservices/v1/tcp_route.proto/google/cloud/networkservices/v1/tls_route.proto#google/longrunning/operations.proto2H -NetworkServices -ListEndpointPolicies<.google.cloud.networkservices.v1.ListEndpointPoliciesRequest=.google.cloud.networkservices.v1.ListEndpointPoliciesResponse"EAparent64/v1/{parent=projects/*/locations/*}/endpointPolicies -GetEndpointPolicy9.google.cloud.networkservices.v1.GetEndpointPolicyRequest/.google.cloud.networkservices.v1.EndpointPolicy"CAname64/v1/{name=projects/*/locations/*/endpointPolicies/*} -CreateEndpointPolicy<.google.cloud.networkservices.v1.CreateEndpointPolicyRequest.google.longrunning.Operation"AC -EndpointPolicy1google.cloud.networkservices.v1.OperationMetadataA)parent,endpoint_policy,endpoint_policy_idG"4/v1/{parent=projects/*/locations/*}/endpointPolicies:endpoint_policy -UpdateEndpointPolicy<.google.cloud.networkservices.v1.UpdateEndpointPolicyRequest.google.longrunning.Operation"AC -EndpointPolicy1google.cloud.networkservices.v1.OperationMetadataAendpoint_policy,update_maskW2D/v1/{endpoint_policy.name=projects/*/locations/*/endpointPolicies/*}:endpoint_policy -DeleteEndpointPolicy<.google.cloud.networkservices.v1.DeleteEndpointPolicyRequest.google.longrunning.Operation"AJ -google.protobuf.Empty1google.cloud.networkservices.v1.OperationMetadataAname6*4/v1/{name=projects/*/locations/*/endpointPolicies/*} - ListGateways4.google.cloud.networkservices.v1.ListGatewaysRequest5.google.cloud.networkservices.v1.ListGatewaysResponse"=Aparent.,/v1/{parent=projects/*/locations/*}/gateways - -GetGateway2.google.cloud.networkservices.v1.GetGatewayRequest(.google.cloud.networkservices.v1.Gateway";Aname.,/v1/{name=projects/*/locations/*/gateways/*} - CreateGateway5.google.cloud.networkservices.v1.CreateGatewayRequest.google.longrunning.Operation"A< -Gateway1google.cloud.networkservices.v1.OperationMetadataAparent,gateway,gateway_id7",/v1/{parent=projects/*/locations/*}/gateways:gateway - UpdateGateway5.google.cloud.networkservices.v1.UpdateGatewayRequest.google.longrunning.Operation"A< -Gateway1google.cloud.networkservices.v1.OperationMetadataAgateway,update_mask?24/v1/{gateway.name=projects/*/locations/*/gateways/*}:gateway - DeleteGateway5.google.cloud.networkservices.v1.DeleteGatewayRequest.google.longrunning.Operation"AJ -google.protobuf.Empty1google.cloud.networkservices.v1.OperationMetadataAname.*,/v1/{name=projects/*/locations/*/gateways/*} -ListGrpcRoutes6.google.cloud.networkservices.v1.ListGrpcRoutesRequest7.google.cloud.networkservices.v1.ListGrpcRoutesResponse"?Aparent0./v1/{parent=projects/*/locations/*}/grpcRoutes - GetGrpcRoute4.google.cloud.networkservices.v1.GetGrpcRouteRequest*.google.cloud.networkservices.v1.GrpcRoute"=Aname0./v1/{name=projects/*/locations/*/grpcRoutes/*} -CreateGrpcRoute7.google.cloud.networkservices.v1.CreateGrpcRouteRequest.google.longrunning.Operation"A> - GrpcRoute1google.cloud.networkservices.v1.OperationMetadataAparent,grpc_route,grpc_route_id<"./v1/{parent=projects/*/locations/*}/grpcRoutes: -grpc_route -UpdateGrpcRoute7.google.cloud.networkservices.v1.UpdateGrpcRouteRequest.google.longrunning.Operation"A> - GrpcRoute1google.cloud.networkservices.v1.OperationMetadataAgrpc_route,update_maskG29/v1/{grpc_route.name=projects/*/locations/*/grpcRoutes/*}: -grpc_route -DeleteGrpcRoute7.google.cloud.networkservices.v1.DeleteGrpcRouteRequest.google.longrunning.Operation"AJ -google.protobuf.Empty1google.cloud.networkservices.v1.OperationMetadataAname0*./v1/{name=projects/*/locations/*/grpcRoutes/*} -ListHttpRoutes6.google.cloud.networkservices.v1.ListHttpRoutesRequest7.google.cloud.networkservices.v1.ListHttpRoutesResponse"?Aparent0./v1/{parent=projects/*/locations/*}/httpRoutes - GetHttpRoute4.google.cloud.networkservices.v1.GetHttpRouteRequest*.google.cloud.networkservices.v1.HttpRoute"=Aname0./v1/{name=projects/*/locations/*/httpRoutes/*} -CreateHttpRoute7.google.cloud.networkservices.v1.CreateHttpRouteRequest.google.longrunning.Operation"A> - HttpRoute1google.cloud.networkservices.v1.OperationMetadataAparent,http_route,http_route_id<"./v1/{parent=projects/*/locations/*}/httpRoutes: -http_route -UpdateHttpRoute7.google.cloud.networkservices.v1.UpdateHttpRouteRequest.google.longrunning.Operation"A> - HttpRoute1google.cloud.networkservices.v1.OperationMetadataAhttp_route,update_maskG29/v1/{http_route.name=projects/*/locations/*/httpRoutes/*}: -http_route -DeleteHttpRoute7.google.cloud.networkservices.v1.DeleteHttpRouteRequest.google.longrunning.Operation"AJ -google.protobuf.Empty1google.cloud.networkservices.v1.OperationMetadataAname0*./v1/{name=projects/*/locations/*/httpRoutes/*} - ListTcpRoutes5.google.cloud.networkservices.v1.ListTcpRoutesRequest6.google.cloud.networkservices.v1.ListTcpRoutesResponse">Aparent/-/v1/{parent=projects/*/locations/*}/tcpRoutes - GetTcpRoute3.google.cloud.networkservices.v1.GetTcpRouteRequest).google.cloud.networkservices.v1.TcpRoute"Aparent/-/v1/{parent=projects/*/locations/*}/tlsRoutes - GetTlsRoute3.google.cloud.networkservices.v1.GetTlsRouteRequest).google.cloud.networkservices.v1.TlsRoute"internalAddGeneratedFile( - ' - -5google/cloud/networkservices/v1/service_binding.protogoogle.cloud.networkservices.v1google/api/resource.protogoogle/protobuf/timestamp.proto" -ServiceBinding -name ( BA - description ( BA4 - create_time ( 2.google.protobuf.TimestampBA4 - update_time ( 2.google.protobuf.TimestampBA -service ( BAP -labels ( 2;.google.cloud.networkservices.v1.ServiceBinding.LabelsEntryBA- - LabelsEntry -key (  -value ( :8:}Az --networkservices.googleapis.com/ServiceBindingIprojects/{project}/locations/{location}/serviceBindings/{service_binding}" -ListServiceBindingsRequestE -parent ( B5AA/-networkservices.googleapis.com/ServiceBinding - page_size ( - -page_token ( " -ListServiceBindingsResponseI -service_bindings ( 2/.google.cloud.networkservices.v1.ServiceBinding -next_page_token ( "_ -GetServiceBindingRequestC -name ( B5AA/ --networkservices.googleapis.com/ServiceBinding" -CreateServiceBindingRequestE -parent ( B5AA/-networkservices.googleapis.com/ServiceBinding -service_binding_id ( BAM -service_binding ( 2/.google.cloud.networkservices.v1.ServiceBindingBA"b -DeleteServiceBindingRequestC -name ( B5AA/ --networkservices.googleapis.com/ServiceBindingB -#com.google.cloud.networkservices.v1BServiceBindingProtoPZMcloud.google.com/go/networkservices/apiv1/networkservicespb;networkservicespbGoogle.Cloud.NetworkServices.V1Google\\Cloud\\NetworkServices\\V1"Google::Cloud::NetworkServices::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TcpRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TcpRoute.php deleted file mode 100644 index 35505dfd4a1c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TcpRoute.php +++ /dev/null @@ -1,85 +0,0 @@ -internalAddGeneratedFile( - ' - -/google/cloud/networkservices/v1/tcp_route.protogoogle.cloud.networkservices.v1google/api/resource.proto google/protobuf/field_mask.protogoogle/protobuf/timestamp.proto" -TcpRoute -name ( BA - self_link ( BA4 - create_time ( 2.google.protobuf.TimestampBA4 - update_time ( 2.google.protobuf.TimestampBA - description ( BAG -rules ( 23.google.cloud.networkservices.v1.TcpRoute.RouteRuleBA; -meshes ( B+AA% -#networkservices.googleapis.com/Mesh@ -gateways ( B.AA( -&networkservices.googleapis.com/GatewayJ -labels - ( 25.google.cloud.networkservices.v1.TcpRoute.LabelsEntryBA - RouteRuleJ -matches ( 24.google.cloud.networkservices.v1.TcpRoute.RouteMatchBAJ -action ( 25.google.cloud.networkservices.v1.TcpRoute.RouteActionBA5 - -RouteMatch -address ( BA -port ( BA - RouteActionU - destinations ( 2:.google.cloud.networkservices.v1.TcpRoute.RouteDestinationBA! -original_destination (BAl -RouteDestinationC - service_name ( B-AA\' -%compute.googleapis.com/BackendService -weight (BA- - LabelsEntry -key (  -value ( :8:kAh -\'networkservices.googleapis.com/TcpRoute=projects/{project}/locations/{location}/tcpRoutes/{tcp_route}"~ -ListTcpRoutesRequest? -parent ( B/AA)\'networkservices.googleapis.com/TcpRoute - page_size ( - -page_token ( "o -ListTcpRoutesResponse= - -tcp_routes ( 2).google.cloud.networkservices.v1.TcpRoute -next_page_token ( "S -GetTcpRouteRequest= -name ( B/AA) -\'networkservices.googleapis.com/TcpRoute" -CreateTcpRouteRequest? -parent ( B/AA)\'networkservices.googleapis.com/TcpRoute - tcp_route_id ( BAA - tcp_route ( 2).google.cloud.networkservices.v1.TcpRouteBA" -UpdateTcpRouteRequest4 - update_mask ( 2.google.protobuf.FieldMaskBAA - tcp_route ( 2).google.cloud.networkservices.v1.TcpRouteBA"V -DeleteTcpRouteRequest= -name ( B/AA) -\'networkservices.googleapis.com/TcpRouteB -#com.google.cloud.networkservices.v1B TcpRouteProtoPZMcloud.google.com/go/networkservices/apiv1/networkservicespb;networkservicespbGoogle.Cloud.NetworkServices.V1Google\\Cloud\\NetworkServices\\V1"Google::Cloud::NetworkServices::V1Ar -%compute.googleapis.com/BackendServiceIprojects/{project}/locations/{location}/backendServices/{backend_service}bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TlsRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TlsRoute.php deleted file mode 100644 index 1687a1119d3c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/GPBMetadata/Google/Cloud/Networkservices/V1/TlsRoute.php +++ /dev/null @@ -1,78 +0,0 @@ -internalAddGeneratedFile( - ' - -/google/cloud/networkservices/v1/tls_route.protogoogle.cloud.networkservices.v1google/api/resource.proto google/protobuf/field_mask.protogoogle/protobuf/timestamp.proto" -TlsRoute -name ( BA - self_link ( BA4 - create_time ( 2.google.protobuf.TimestampBA4 - update_time ( 2.google.protobuf.TimestampBA - description ( BAG -rules ( 23.google.cloud.networkservices.v1.TlsRoute.RouteRuleBA; -meshes ( B+AA% -#networkservices.googleapis.com/Mesh@ -gateways ( B.AA( -&networkservices.googleapis.com/Gateway - RouteRuleJ -matches ( 24.google.cloud.networkservices.v1.TlsRoute.RouteMatchBAJ -action ( 25.google.cloud.networkservices.v1.TlsRoute.RouteActionBA6 - -RouteMatch -sni_host ( BA -alpn ( BAd - RouteActionU - destinations ( 2:.google.cloud.networkservices.v1.TlsRoute.RouteDestinationBAl -RouteDestinationC - service_name ( B-AA\' -%compute.googleapis.com/BackendService -weight (BA:kAh -\'networkservices.googleapis.com/TlsRoute=projects/{project}/locations/{location}/tlsRoutes/{tls_route}"~ -ListTlsRoutesRequest? -parent ( B/AA)\'networkservices.googleapis.com/TlsRoute - page_size ( - -page_token ( "o -ListTlsRoutesResponse= - -tls_routes ( 2).google.cloud.networkservices.v1.TlsRoute -next_page_token ( "S -GetTlsRouteRequest= -name ( B/AA) -\'networkservices.googleapis.com/TlsRoute" -CreateTlsRouteRequest? -parent ( B/AA)\'networkservices.googleapis.com/TlsRoute - tls_route_id ( BAA - tls_route ( 2).google.cloud.networkservices.v1.TlsRouteBA" -UpdateTlsRouteRequest4 - update_mask ( 2.google.protobuf.FieldMaskBAA - tls_route ( 2).google.cloud.networkservices.v1.TlsRouteBA"V -DeleteTlsRouteRequest= -name ( B/AA) -\'networkservices.googleapis.com/TlsRouteB -#com.google.cloud.networkservices.v1B TlsRouteProtoPZMcloud.google.com/go/networkservices/apiv1/networkservicespb;networkservicespbGoogle.Cloud.NetworkServices.V1Google\\Cloud\\NetworkServices\\V1"Google::Cloud::NetworkServices::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateEndpointPolicyRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateEndpointPolicyRequest.php deleted file mode 100644 index c6dfd22a5f8c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateEndpointPolicyRequest.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.networkservices.v1.CreateEndpointPolicyRequest - */ -class CreateEndpointPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the EndpointPolicy. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the EndpointPolicy resource to be created. - * E.g. "CustomECS". - * - * Generated from protobuf field string endpoint_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $endpoint_policy_id = ''; - /** - * Required. EndpointPolicy resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $endpoint_policy = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the EndpointPolicy. Must be in the - * format `projects/*/locations/global`. - * @type string $endpoint_policy_id - * Required. Short name of the EndpointPolicy resource to be created. - * E.g. "CustomECS". - * @type \Google\Cloud\NetworkServices\V1\EndpointPolicy $endpoint_policy - * Required. EndpointPolicy resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the EndpointPolicy. Must be in the - * format `projects/*/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 parent resource of the EndpointPolicy. Must be in the - * format `projects/*/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. Short name of the EndpointPolicy resource to be created. - * E.g. "CustomECS". - * - * Generated from protobuf field string endpoint_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getEndpointPolicyId() - { - return $this->endpoint_policy_id; - } - - /** - * Required. Short name of the EndpointPolicy resource to be created. - * E.g. "CustomECS". - * - * Generated from protobuf field string endpoint_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setEndpointPolicyId($var) - { - GPBUtil::checkString($var, True); - $this->endpoint_policy_id = $var; - - return $this; - } - - /** - * Required. EndpointPolicy resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\EndpointPolicy|null - */ - public function getEndpointPolicy() - { - return $this->endpoint_policy; - } - - public function hasEndpointPolicy() - { - return isset($this->endpoint_policy); - } - - public function clearEndpointPolicy() - { - unset($this->endpoint_policy); - } - - /** - * Required. EndpointPolicy resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\EndpointPolicy $var - * @return $this - */ - public function setEndpointPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\EndpointPolicy::class); - $this->endpoint_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGatewayRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGatewayRequest.php deleted file mode 100644 index 6f322da461a6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGatewayRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateGatewayRequest - */ -class CreateGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the Gateway. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the Gateway resource to be created. - * - * Generated from protobuf field string gateway_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $gateway_id = ''; - /** - * Required. Gateway resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $gateway = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the Gateway. Must be in the - * format `projects/*/locations/*`. - * @type string $gateway_id - * Required. Short name of the Gateway resource to be created. - * @type \Google\Cloud\NetworkServices\V1\Gateway $gateway - * Required. Gateway resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the Gateway. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the Gateway. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Short name of the Gateway resource to be created. - * - * Generated from protobuf field string gateway_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGatewayId() - { - return $this->gateway_id; - } - - /** - * Required. Short name of the Gateway resource to be created. - * - * Generated from protobuf field string gateway_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGatewayId($var) - { - GPBUtil::checkString($var, True); - $this->gateway_id = $var; - - return $this; - } - - /** - * Required. Gateway resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\Gateway|null - */ - public function getGateway() - { - return $this->gateway; - } - - public function hasGateway() - { - return isset($this->gateway); - } - - public function clearGateway() - { - unset($this->gateway); - } - - /** - * Required. Gateway resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\Gateway $var - * @return $this - */ - public function setGateway($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\Gateway::class); - $this->gateway = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGrpcRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGrpcRouteRequest.php deleted file mode 100644 index cf754379ca47..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateGrpcRouteRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateGrpcRouteRequest - */ -class CreateGrpcRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the GrpcRoute. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the GrpcRoute resource to be created. - * - * Generated from protobuf field string grpc_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $grpc_route_id = ''; - /** - * Required. GrpcRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $grpc_route = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the GrpcRoute. Must be in the - * format `projects/*/locations/global`. - * @type string $grpc_route_id - * Required. Short name of the GrpcRoute resource to be created. - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute $grpc_route - * Required. GrpcRoute resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the GrpcRoute. Must be in the - * format `projects/*/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 parent resource of the GrpcRoute. Must be in the - * format `projects/*/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. Short name of the GrpcRoute resource to be created. - * - * Generated from protobuf field string grpc_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGrpcRouteId() - { - return $this->grpc_route_id; - } - - /** - * Required. Short name of the GrpcRoute resource to be created. - * - * Generated from protobuf field string grpc_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGrpcRouteId($var) - { - GPBUtil::checkString($var, True); - $this->grpc_route_id = $var; - - return $this; - } - - /** - * Required. GrpcRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute|null - */ - public function getGrpcRoute() - { - return $this->grpc_route; - } - - public function hasGrpcRoute() - { - return isset($this->grpc_route); - } - - public function clearGrpcRoute() - { - unset($this->grpc_route); - } - - /** - * Required. GrpcRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute $var - * @return $this - */ - public function setGrpcRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute::class); - $this->grpc_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateHttpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateHttpRouteRequest.php deleted file mode 100644 index a14312ab5e4a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateHttpRouteRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateHttpRouteRequest - */ -class CreateHttpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the HttpRoute. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the HttpRoute resource to be created. - * - * Generated from protobuf field string http_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $http_route_id = ''; - /** - * Required. HttpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $http_route = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the HttpRoute. Must be in the - * format `projects/*/locations/global`. - * @type string $http_route_id - * Required. Short name of the HttpRoute resource to be created. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute $http_route - * Required. HttpRoute resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the HttpRoute. Must be in the - * format `projects/*/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 parent resource of the HttpRoute. Must be in the - * format `projects/*/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. Short name of the HttpRoute resource to be created. - * - * Generated from protobuf field string http_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getHttpRouteId() - { - return $this->http_route_id; - } - - /** - * Required. Short name of the HttpRoute resource to be created. - * - * Generated from protobuf field string http_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setHttpRouteId($var) - { - GPBUtil::checkString($var, True); - $this->http_route_id = $var; - - return $this; - } - - /** - * Required. HttpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute|null - */ - public function getHttpRoute() - { - return $this->http_route; - } - - public function hasHttpRoute() - { - return isset($this->http_route); - } - - public function clearHttpRoute() - { - unset($this->http_route); - } - - /** - * Required. HttpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute $var - * @return $this - */ - public function setHttpRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute::class); - $this->http_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbRouteExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbRouteExtensionRequest.php deleted file mode 100644 index b4d77055dfb2..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbRouteExtensionRequest.php +++ /dev/null @@ -1,227 +0,0 @@ -google.cloud.networkservices.v1.CreateLbRouteExtensionRequest - */ -class CreateLbRouteExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the `LbRouteExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. User-provided ID of the `LbRouteExtension` resource to be - * created. - * - * Generated from protobuf field string lb_route_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_route_extension_id = ''; - /** - * Required. `LbRouteExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_route_extension = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the `LbRouteExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * @type string $lb_route_extension_id - * Required. User-provided ID of the `LbRouteExtension` resource to be - * created. - * @type \Google\Cloud\NetworkServices\V1\LbRouteExtension $lb_route_extension - * Required. `LbRouteExtension` resource to be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the `LbRouteExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the `LbRouteExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. User-provided ID of the `LbRouteExtension` resource to be - * created. - * - * Generated from protobuf field string lb_route_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLbRouteExtensionId() - { - return $this->lb_route_extension_id; - } - - /** - * Required. User-provided ID of the `LbRouteExtension` resource to be - * created. - * - * Generated from protobuf field string lb_route_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLbRouteExtensionId($var) - { - GPBUtil::checkString($var, True); - $this->lb_route_extension_id = $var; - - return $this; - } - - /** - * Required. `LbRouteExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\LbRouteExtension|null - */ - public function getLbRouteExtension() - { - return $this->lb_route_extension; - } - - public function hasLbRouteExtension() - { - return isset($this->lb_route_extension); - } - - public function clearLbRouteExtension() - { - unset($this->lb_route_extension); - } - - /** - * Required. `LbRouteExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\LbRouteExtension $var - * @return $this - */ - public function setLbRouteExtension($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\LbRouteExtension::class); - $this->lb_route_extension = $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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbTrafficExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbTrafficExtensionRequest.php deleted file mode 100644 index d22d3c89205c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateLbTrafficExtensionRequest.php +++ /dev/null @@ -1,227 +0,0 @@ -google.cloud.networkservices.v1.CreateLbTrafficExtensionRequest - */ -class CreateLbTrafficExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the `LbTrafficExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. User-provided ID of the `LbTrafficExtension` resource to be - * created. - * - * Generated from protobuf field string lb_traffic_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_traffic_extension_id = ''; - /** - * Required. `LbTrafficExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_traffic_extension = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the `LbTrafficExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * @type string $lb_traffic_extension_id - * Required. User-provided ID of the `LbTrafficExtension` resource to be - * created. - * @type \Google\Cloud\NetworkServices\V1\LbTrafficExtension $lb_traffic_extension - * Required. `LbTrafficExtension` resource to be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the `LbTrafficExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the `LbTrafficExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. User-provided ID of the `LbTrafficExtension` resource to be - * created. - * - * Generated from protobuf field string lb_traffic_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLbTrafficExtensionId() - { - return $this->lb_traffic_extension_id; - } - - /** - * Required. User-provided ID of the `LbTrafficExtension` resource to be - * created. - * - * Generated from protobuf field string lb_traffic_extension_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLbTrafficExtensionId($var) - { - GPBUtil::checkString($var, True); - $this->lb_traffic_extension_id = $var; - - return $this; - } - - /** - * Required. `LbTrafficExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\LbTrafficExtension|null - */ - public function getLbTrafficExtension() - { - return $this->lb_traffic_extension; - } - - public function hasLbTrafficExtension() - { - return isset($this->lb_traffic_extension); - } - - public function clearLbTrafficExtension() - { - unset($this->lb_traffic_extension); - } - - /** - * Required. `LbTrafficExtension` resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\LbTrafficExtension $var - * @return $this - */ - public function setLbTrafficExtension($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\LbTrafficExtension::class); - $this->lb_traffic_extension = $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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateMeshRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateMeshRequest.php deleted file mode 100644 index b563e82b165d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateMeshRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateMeshRequest - */ -class CreateMeshRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the Mesh. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the Mesh resource to be created. - * - * Generated from protobuf field string mesh_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mesh_id = ''; - /** - * Required. Mesh resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mesh = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the Mesh. Must be in the - * format `projects/*/locations/global`. - * @type string $mesh_id - * Required. Short name of the Mesh resource to be created. - * @type \Google\Cloud\NetworkServices\V1\Mesh $mesh - * Required. Mesh resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the Mesh. Must be in the - * format `projects/*/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 parent resource of the Mesh. Must be in the - * format `projects/*/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. Short name of the Mesh resource to be created. - * - * Generated from protobuf field string mesh_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getMeshId() - { - return $this->mesh_id; - } - - /** - * Required. Short name of the Mesh resource to be created. - * - * Generated from protobuf field string mesh_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setMeshId($var) - { - GPBUtil::checkString($var, True); - $this->mesh_id = $var; - - return $this; - } - - /** - * Required. Mesh resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\Mesh|null - */ - public function getMesh() - { - return $this->mesh; - } - - public function hasMesh() - { - return isset($this->mesh); - } - - public function clearMesh() - { - unset($this->mesh); - } - - /** - * Required. Mesh resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\Mesh $var - * @return $this - */ - public function setMesh($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\Mesh::class); - $this->mesh = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateServiceBindingRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateServiceBindingRequest.php deleted file mode 100644 index 1f35c7a500e5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateServiceBindingRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateServiceBindingRequest - */ -class CreateServiceBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the ServiceBinding. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the ServiceBinding resource to be created. - * - * Generated from protobuf field string service_binding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_binding_id = ''; - /** - * Required. ServiceBinding resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ServiceBinding service_binding = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_binding = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the ServiceBinding. Must be in the - * format `projects/*/locations/global`. - * @type string $service_binding_id - * Required. Short name of the ServiceBinding resource to be created. - * @type \Google\Cloud\NetworkServices\V1\ServiceBinding $service_binding - * Required. ServiceBinding resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the ServiceBinding. Must be in the - * format `projects/*/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 parent resource of the ServiceBinding. Must be in the - * format `projects/*/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. Short name of the ServiceBinding resource to be created. - * - * Generated from protobuf field string service_binding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceBindingId() - { - return $this->service_binding_id; - } - - /** - * Required. Short name of the ServiceBinding resource to be created. - * - * Generated from protobuf field string service_binding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceBindingId($var) - { - GPBUtil::checkString($var, True); - $this->service_binding_id = $var; - - return $this; - } - - /** - * Required. ServiceBinding resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ServiceBinding service_binding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\ServiceBinding|null - */ - public function getServiceBinding() - { - return $this->service_binding; - } - - public function hasServiceBinding() - { - return isset($this->service_binding); - } - - public function clearServiceBinding() - { - unset($this->service_binding); - } - - /** - * Required. ServiceBinding resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ServiceBinding service_binding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\ServiceBinding $var - * @return $this - */ - public function setServiceBinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\ServiceBinding::class); - $this->service_binding = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTcpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTcpRouteRequest.php deleted file mode 100644 index 77daad17011e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTcpRouteRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateTcpRouteRequest - */ -class CreateTcpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the TcpRoute. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the TcpRoute resource to be created. - * - * Generated from protobuf field string tcp_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tcp_route_id = ''; - /** - * Required. TcpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tcp_route = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the TcpRoute. Must be in the - * format `projects/*/locations/global`. - * @type string $tcp_route_id - * Required. Short name of the TcpRoute resource to be created. - * @type \Google\Cloud\NetworkServices\V1\TcpRoute $tcp_route - * Required. TcpRoute resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the TcpRoute. Must be in the - * format `projects/*/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 parent resource of the TcpRoute. Must be in the - * format `projects/*/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. Short name of the TcpRoute resource to be created. - * - * Generated from protobuf field string tcp_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTcpRouteId() - { - return $this->tcp_route_id; - } - - /** - * Required. Short name of the TcpRoute resource to be created. - * - * Generated from protobuf field string tcp_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTcpRouteId($var) - { - GPBUtil::checkString($var, True); - $this->tcp_route_id = $var; - - return $this; - } - - /** - * Required. TcpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TcpRoute|null - */ - public function getTcpRoute() - { - return $this->tcp_route; - } - - public function hasTcpRoute() - { - return isset($this->tcp_route); - } - - public function clearTcpRoute() - { - unset($this->tcp_route); - } - - /** - * Required. TcpRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TcpRoute $var - * @return $this - */ - public function setTcpRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TcpRoute::class); - $this->tcp_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTlsRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTlsRouteRequest.php deleted file mode 100644 index 3b8efdfc7adb..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/CreateTlsRouteRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.CreateTlsRouteRequest - */ -class CreateTlsRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the TlsRoute. Must be in the - * format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Short name of the TlsRoute resource to be created. - * - * Generated from protobuf field string tls_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tls_route_id = ''; - /** - * Required. TlsRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tls_route = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the TlsRoute. Must be in the - * format `projects/*/locations/global`. - * @type string $tls_route_id - * Required. Short name of the TlsRoute resource to be created. - * @type \Google\Cloud\NetworkServices\V1\TlsRoute $tls_route - * Required. TlsRoute resource to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the TlsRoute. Must be in the - * format `projects/*/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 parent resource of the TlsRoute. Must be in the - * format `projects/*/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. Short name of the TlsRoute resource to be created. - * - * Generated from protobuf field string tls_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTlsRouteId() - { - return $this->tls_route_id; - } - - /** - * Required. Short name of the TlsRoute resource to be created. - * - * Generated from protobuf field string tls_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTlsRouteId($var) - { - GPBUtil::checkString($var, True); - $this->tls_route_id = $var; - - return $this; - } - - /** - * Required. TlsRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TlsRoute|null - */ - public function getTlsRoute() - { - return $this->tls_route; - } - - public function hasTlsRoute() - { - return isset($this->tls_route); - } - - public function clearTlsRoute() - { - unset($this->tls_route); - } - - /** - * Required. TlsRoute resource to be created. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TlsRoute $var - * @return $this - */ - public function setTlsRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TlsRoute::class); - $this->tls_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteEndpointPolicyRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteEndpointPolicyRequest.php deleted file mode 100644 index 67da0d66c369..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteEndpointPolicyRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteEndpointPolicyRequest - */ -class DeleteEndpointPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the EndpointPolicy to delete. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * 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. A name of the EndpointPolicy to delete. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the EndpointPolicy to delete. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the EndpointPolicy to delete. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGatewayRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGatewayRequest.php deleted file mode 100644 index a476f6e4aada..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGatewayRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteGatewayRequest - */ -class DeleteGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the Gateway to delete. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * 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. A name of the Gateway to delete. Must be in the format - * `projects/*/locations/*/gateways/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the Gateway to delete. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the Gateway to delete. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGrpcRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGrpcRouteRequest.php deleted file mode 100644 index b39a2e36f98b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteGrpcRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteGrpcRouteRequest - */ -class DeleteGrpcRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the GrpcRoute to delete. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * 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. A name of the GrpcRoute to delete. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the GrpcRoute to delete. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the GrpcRoute to delete. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteHttpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteHttpRouteRequest.php deleted file mode 100644 index ece4a3988fdd..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteHttpRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteHttpRouteRequest - */ -class DeleteHttpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the HttpRoute to delete. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * 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. A name of the HttpRoute to delete. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the HttpRoute to delete. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the HttpRoute to delete. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbRouteExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbRouteExtensionRequest.php deleted file mode 100644 index c85d32350f47..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbRouteExtensionRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.DeleteLbRouteExtensionRequest - */ -class DeleteLbRouteExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the `LbRouteExtension` resource to delete. Must be in - * the format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the `LbRouteExtension` resource to delete. Must be in - * the format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * @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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the `LbRouteExtension` resource to delete. Must be in - * the format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * 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 `LbRouteExtension` resource to delete. Must be in - * the format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbTrafficExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbTrafficExtensionRequest.php deleted file mode 100644 index 37b363179f7f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteLbTrafficExtensionRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.networkservices.v1.DeleteLbTrafficExtensionRequest - */ -class DeleteLbTrafficExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the `LbTrafficExtension` resource to delete. Must be - * in the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the `LbTrafficExtension` resource to delete. Must be - * in the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * @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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the `LbTrafficExtension` resource to delete. Must be - * in the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * 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 `LbTrafficExtension` resource to delete. Must be - * in the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteMeshRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteMeshRequest.php deleted file mode 100644 index 04581c6f16d5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteMeshRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteMeshRequest - */ -class DeleteMeshRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the Mesh to delete. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * 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. A name of the Mesh to delete. Must be in the format - * `projects/*/locations/global/meshes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the Mesh to delete. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the Mesh to delete. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteServiceBindingRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteServiceBindingRequest.php deleted file mode 100644 index b7c9e7b99b11..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteServiceBindingRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteServiceBindingRequest - */ -class DeleteServiceBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the ServiceBinding to delete. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * 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. A name of the ServiceBinding to delete. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the ServiceBinding to delete. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the ServiceBinding to delete. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTcpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTcpRouteRequest.php deleted file mode 100644 index c22688511054..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTcpRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteTcpRouteRequest - */ -class DeleteTcpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the TcpRoute to delete. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * 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. A name of the TcpRoute to delete. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the TcpRoute to delete. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the TcpRoute to delete. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTlsRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTlsRouteRequest.php deleted file mode 100644 index 2d3eaffd3ac1..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/DeleteTlsRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.DeleteTlsRouteRequest - */ -class DeleteTlsRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the TlsRoute to delete. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * 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. A name of the TlsRoute to delete. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the TlsRoute to delete. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the TlsRoute to delete. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher.php deleted file mode 100644 index e03be7be44e8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher.php +++ /dev/null @@ -1,76 +0,0 @@ -google.cloud.networkservices.v1.EndpointMatcher - */ -class EndpointMatcher extends \Google\Protobuf\Internal\Message -{ - protected $matcher_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher $metadata_label_matcher - * The matcher is based on node metadata presented by xDS clients. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * The matcher is based on node metadata presented by xDS clients. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher metadata_label_matcher = 1; - * @return \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher|null - */ - public function getMetadataLabelMatcher() - { - return $this->readOneof(1); - } - - public function hasMetadataLabelMatcher() - { - return $this->hasOneof(1); - } - - /** - * The matcher is based on node metadata presented by xDS clients. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher metadata_label_matcher = 1; - * @param \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher $var - * @return $this - */ - public function setMetadataLabelMatcher($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getMatcherType() - { - return $this->whichOneof("matcher_type"); - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher.php deleted file mode 100644 index dd0d98126ecf..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher.php +++ /dev/null @@ -1,196 +0,0 @@ -google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher - */ -class MetadataLabelMatcher extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies how matching should be done. - * Supported values are: - * MATCH_ANY: At least one of the Labels specified in the - * matcher should match the metadata presented by xDS client. - * MATCH_ALL: The metadata presented by the xDS client should - * contain all of the labels specified here. - * The selection is determined based on the best match. For - * example, suppose there are three EndpointPolicy - * resources P1, P2 and P3 and if P1 has a the matcher as - * MATCH_ANY , P2 has MATCH_ALL , and P3 has - * MATCH_ALL . - * If a client with label connects, the config from P1 - * will be selected. - * If a client with label connects, the config from P2 - * will be selected. - * If a client with label connects, the config - * from P3 will be selected. - * If there is more than one best match, (for example, if a - * config P4 with selector exists and if a client with - * label connects), an error will be thrown. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria metadata_label_match_criteria = 1; - */ - protected $metadata_label_match_criteria = 0; - /** - * The list of label value pairs that must match labels in the - * provided metadata based on filterMatchCriteria This list can - * have at most 64 entries. The list can be empty if the match - * criteria is MATCH_ANY, to specify a wildcard match (i.e this - * matches any client). - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2; - */ - private $metadata_labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $metadata_label_match_criteria - * Specifies how matching should be done. - * Supported values are: - * MATCH_ANY: At least one of the Labels specified in the - * matcher should match the metadata presented by xDS client. - * MATCH_ALL: The metadata presented by the xDS client should - * contain all of the labels specified here. - * The selection is determined based on the best match. For - * example, suppose there are three EndpointPolicy - * resources P1, P2 and P3 and if P1 has a the matcher as - * MATCH_ANY , P2 has MATCH_ALL , and P3 has - * MATCH_ALL . - * If a client with label connects, the config from P1 - * will be selected. - * If a client with label connects, the config from P2 - * will be selected. - * If a client with label connects, the config - * from P3 will be selected. - * If there is more than one best match, (for example, if a - * config P4 with selector exists and if a client with - * label connects), an error will be thrown. - * @type array<\Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher\MetadataLabels>|\Google\Protobuf\Internal\RepeatedField $metadata_labels - * The list of label value pairs that must match labels in the - * provided metadata based on filterMatchCriteria This list can - * have at most 64 entries. The list can be empty if the match - * criteria is MATCH_ANY, to specify a wildcard match (i.e this - * matches any client). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Specifies how matching should be done. - * Supported values are: - * MATCH_ANY: At least one of the Labels specified in the - * matcher should match the metadata presented by xDS client. - * MATCH_ALL: The metadata presented by the xDS client should - * contain all of the labels specified here. - * The selection is determined based on the best match. For - * example, suppose there are three EndpointPolicy - * resources P1, P2 and P3 and if P1 has a the matcher as - * MATCH_ANY , P2 has MATCH_ALL , and P3 has - * MATCH_ALL . - * If a client with label connects, the config from P1 - * will be selected. - * If a client with label connects, the config from P2 - * will be selected. - * If a client with label connects, the config - * from P3 will be selected. - * If there is more than one best match, (for example, if a - * config P4 with selector exists and if a client with - * label connects), an error will be thrown. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria metadata_label_match_criteria = 1; - * @return int - */ - public function getMetadataLabelMatchCriteria() - { - return $this->metadata_label_match_criteria; - } - - /** - * Specifies how matching should be done. - * Supported values are: - * MATCH_ANY: At least one of the Labels specified in the - * matcher should match the metadata presented by xDS client. - * MATCH_ALL: The metadata presented by the xDS client should - * contain all of the labels specified here. - * The selection is determined based on the best match. For - * example, suppose there are three EndpointPolicy - * resources P1, P2 and P3 and if P1 has a the matcher as - * MATCH_ANY , P2 has MATCH_ALL , and P3 has - * MATCH_ALL . - * If a client with label connects, the config from P1 - * will be selected. - * If a client with label connects, the config from P2 - * will be selected. - * If a client with label connects, the config - * from P3 will be selected. - * If there is more than one best match, (for example, if a - * config P4 with selector exists and if a client with - * label connects), an error will be thrown. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria metadata_label_match_criteria = 1; - * @param int $var - * @return $this - */ - public function setMetadataLabelMatchCriteria($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher\MetadataLabelMatchCriteria::class); - $this->metadata_label_match_criteria = $var; - - return $this; - } - - /** - * The list of label value pairs that must match labels in the - * provided metadata based on filterMatchCriteria This list can - * have at most 64 entries. The list can be empty if the match - * criteria is MATCH_ANY, to specify a wildcard match (i.e this - * matches any client). - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetadataLabels() - { - return $this->metadata_labels; - } - - /** - * The list of label value pairs that must match labels in the - * provided metadata based on filterMatchCriteria This list can - * have at most 64 entries. The list can be empty if the match - * criteria is MATCH_ANY, to specify a wildcard match (i.e this - * matches any client). - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2; - * @param array<\Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher\MetadataLabels>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetadataLabels($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\EndpointMatcher\MetadataLabelMatcher\MetadataLabels::class); - $this->metadata_labels = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MetadataLabelMatcher::class, \Google\Cloud\NetworkServices\V1\EndpointMatcher_MetadataLabelMatcher::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabelMatchCriteria.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabelMatchCriteria.php deleted file mode 100644 index efc8ad586af8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabelMatchCriteria.php +++ /dev/null @@ -1,66 +0,0 @@ -google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria - */ -class MetadataLabelMatchCriteria -{ - /** - * Default value. Should not be used. - * - * Generated from protobuf enum METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED = 0; - */ - const METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED = 0; - /** - * At least one of the Labels specified in the matcher should match the - * metadata presented by xDS client. - * - * Generated from protobuf enum MATCH_ANY = 1; - */ - const MATCH_ANY = 1; - /** - * The metadata presented by the xDS client should contain all of the - * labels specified here. - * - * Generated from protobuf enum MATCH_ALL = 2; - */ - const MATCH_ALL = 2; - - private static $valueToName = [ - self::METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED => 'METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED', - self::MATCH_ANY => 'MATCH_ANY', - self::MATCH_ALL => 'MATCH_ALL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MetadataLabelMatchCriteria::class, \Google\Cloud\NetworkServices\V1\EndpointMatcher_MetadataLabelMatcher_MetadataLabelMatchCriteria::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabels.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabels.php deleted file mode 100644 index 46a7f1ae194f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointMatcher/MetadataLabelMatcher/MetadataLabels.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels - */ -class MetadataLabels extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Label name presented as key in xDS Node Metadata. - * - * Generated from protobuf field string label_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $label_name = ''; - /** - * Required. Label value presented as value corresponding to the above - * key, in xDS Node Metadata. - * - * Generated from protobuf field string label_value = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $label_value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $label_name - * Required. Label name presented as key in xDS Node Metadata. - * @type string $label_value - * Required. Label value presented as value corresponding to the above - * key, in xDS Node Metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Required. Label name presented as key in xDS Node Metadata. - * - * Generated from protobuf field string label_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLabelName() - { - return $this->label_name; - } - - /** - * Required. Label name presented as key in xDS Node Metadata. - * - * Generated from protobuf field string label_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLabelName($var) - { - GPBUtil::checkString($var, True); - $this->label_name = $var; - - return $this; - } - - /** - * Required. Label value presented as value corresponding to the above - * key, in xDS Node Metadata. - * - * Generated from protobuf field string label_value = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLabelValue() - { - return $this->label_value; - } - - /** - * Required. Label value presented as value corresponding to the above - * key, in xDS Node Metadata. - * - * Generated from protobuf field string label_value = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLabelValue($var) - { - GPBUtil::checkString($var, True); - $this->label_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MetadataLabels::class, \Google\Cloud\NetworkServices\V1\EndpointMatcher_MetadataLabelMatcher_MetadataLabels::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy.php deleted file mode 100644 index 1bde99da2ce8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy.php +++ /dev/null @@ -1,526 +0,0 @@ -google.cloud.networkservices.v1.EndpointPolicy - */ -class EndpointPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the EndpointPolicy resource. It matches pattern - * `projects/{project}/locations/global/endpointPolicies/{endpoint_policy}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Set of label tags associated with the EndpointPolicy resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. The type of endpoint policy. This is primarily used to validate - * the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy.EndpointPolicyType type = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Optional. This field specifies the URL of AuthorizationPolicy resource that - * applies authorization policies to the inbound traffic at the - * matched endpoints. Refer to Authorization. If this field is not - * specified, authorization is disabled(no authz checks) for this - * endpoint. - * - * Generated from protobuf field string authorization_policy = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $authorization_policy = ''; - /** - * Required. A matcher that selects endpoints to which the policies should be - * applied. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher endpoint_matcher = 9 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $endpoint_matcher = null; - /** - * Optional. Port selector for the (matched) endpoints. If no port selector is - * provided, the matched config is applied to all ports. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TrafficPortSelector traffic_port_selector = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $traffic_port_selector = null; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. A URL referring to ServerTlsPolicy resource. ServerTlsPolicy is - * used to determine the authentication policy to be applied to terminate the - * inbound traffic at the identified backends. If this field is not set, - * authentication is disabled(open) for this endpoint. - * - * Generated from protobuf field string server_tls_policy = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $server_tls_policy = ''; - /** - * Optional. A URL referring to a ClientTlsPolicy resource. ClientTlsPolicy - * can be set to specify the authentication for traffic from the proxy to the - * actual endpoints. More specifically, it is applied to the outgoing traffic - * from the proxy to the endpoint. This is typically used for sidecar model - * where the proxy identifies itself as endpoint to the control plane, with - * the connection between sidecar and endpoint requiring authentication. If - * this field is not set, authentication is disabled(open). Applicable only - * when EndpointPolicyType is SIDECAR_PROXY. - * - * Generated from protobuf field string client_tls_policy = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $client_tls_policy = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the EndpointPolicy resource. It matches pattern - * `projects/{project}/locations/global/endpointPolicies/{endpoint_policy}`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the EndpointPolicy resource. - * @type int $type - * Required. The type of endpoint policy. This is primarily used to validate - * the configuration. - * @type string $authorization_policy - * Optional. This field specifies the URL of AuthorizationPolicy resource that - * applies authorization policies to the inbound traffic at the - * matched endpoints. Refer to Authorization. If this field is not - * specified, authorization is disabled(no authz checks) for this - * endpoint. - * @type \Google\Cloud\NetworkServices\V1\EndpointMatcher $endpoint_matcher - * Required. A matcher that selects endpoints to which the policies should be - * applied. - * @type \Google\Cloud\NetworkServices\V1\TrafficPortSelector $traffic_port_selector - * Optional. Port selector for the (matched) endpoints. If no port selector is - * provided, the matched config is applied to all ports. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type string $server_tls_policy - * Optional. A URL referring to ServerTlsPolicy resource. ServerTlsPolicy is - * used to determine the authentication policy to be applied to terminate the - * inbound traffic at the identified backends. If this field is not set, - * authentication is disabled(open) for this endpoint. - * @type string $client_tls_policy - * Optional. A URL referring to a ClientTlsPolicy resource. ClientTlsPolicy - * can be set to specify the authentication for traffic from the proxy to the - * actual endpoints. More specifically, it is applied to the outgoing traffic - * from the proxy to the endpoint. This is typically used for sidecar model - * where the proxy identifies itself as endpoint to the control plane, with - * the connection between sidecar and endpoint requiring authentication. If - * this field is not set, authentication is disabled(open). Applicable only - * when EndpointPolicyType is SIDECAR_PROXY. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the EndpointPolicy resource. It matches pattern - * `projects/{project}/locations/global/endpointPolicies/{endpoint_policy}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the EndpointPolicy resource. It matches pattern - * `projects/{project}/locations/global/endpointPolicies/{endpoint_policy}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. Set of label tags associated with the EndpointPolicy resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the EndpointPolicy resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Required. The type of endpoint policy. This is primarily used to validate - * the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy.EndpointPolicyType type = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of endpoint policy. This is primarily used to validate - * the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy.EndpointPolicyType type = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\EndpointPolicy\EndpointPolicyType::class); - $this->type = $var; - - return $this; - } - - /** - * Optional. This field specifies the URL of AuthorizationPolicy resource that - * applies authorization policies to the inbound traffic at the - * matched endpoints. Refer to Authorization. If this field is not - * specified, authorization is disabled(no authz checks) for this - * endpoint. - * - * Generated from protobuf field string authorization_policy = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getAuthorizationPolicy() - { - return $this->authorization_policy; - } - - /** - * Optional. This field specifies the URL of AuthorizationPolicy resource that - * applies authorization policies to the inbound traffic at the - * matched endpoints. Refer to Authorization. If this field is not - * specified, authorization is disabled(no authz checks) for this - * endpoint. - * - * Generated from protobuf field string authorization_policy = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setAuthorizationPolicy($var) - { - GPBUtil::checkString($var, True); - $this->authorization_policy = $var; - - return $this; - } - - /** - * Required. A matcher that selects endpoints to which the policies should be - * applied. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher endpoint_matcher = 9 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\EndpointMatcher|null - */ - public function getEndpointMatcher() - { - return $this->endpoint_matcher; - } - - public function hasEndpointMatcher() - { - return isset($this->endpoint_matcher); - } - - public function clearEndpointMatcher() - { - unset($this->endpoint_matcher); - } - - /** - * Required. A matcher that selects endpoints to which the policies should be - * applied. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointMatcher endpoint_matcher = 9 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\EndpointMatcher $var - * @return $this - */ - public function setEndpointMatcher($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\EndpointMatcher::class); - $this->endpoint_matcher = $var; - - return $this; - } - - /** - * Optional. Port selector for the (matched) endpoints. If no port selector is - * provided, the matched config is applied to all ports. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TrafficPortSelector traffic_port_selector = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\NetworkServices\V1\TrafficPortSelector|null - */ - public function getTrafficPortSelector() - { - return $this->traffic_port_selector; - } - - public function hasTrafficPortSelector() - { - return isset($this->traffic_port_selector); - } - - public function clearTrafficPortSelector() - { - unset($this->traffic_port_selector); - } - - /** - * Optional. Port selector for the (matched) endpoints. If no port selector is - * provided, the matched config is applied to all ports. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TrafficPortSelector traffic_port_selector = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\NetworkServices\V1\TrafficPortSelector $var - * @return $this - */ - public function setTrafficPortSelector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TrafficPortSelector::class); - $this->traffic_port_selector = $var; - - return $this; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. A URL referring to ServerTlsPolicy resource. ServerTlsPolicy is - * used to determine the authentication policy to be applied to terminate the - * inbound traffic at the identified backends. If this field is not set, - * authentication is disabled(open) for this endpoint. - * - * Generated from protobuf field string server_tls_policy = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getServerTlsPolicy() - { - return $this->server_tls_policy; - } - - /** - * Optional. A URL referring to ServerTlsPolicy resource. ServerTlsPolicy is - * used to determine the authentication policy to be applied to terminate the - * inbound traffic at the identified backends. If this field is not set, - * authentication is disabled(open) for this endpoint. - * - * Generated from protobuf field string server_tls_policy = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServerTlsPolicy($var) - { - GPBUtil::checkString($var, True); - $this->server_tls_policy = $var; - - return $this; - } - - /** - * Optional. A URL referring to a ClientTlsPolicy resource. ClientTlsPolicy - * can be set to specify the authentication for traffic from the proxy to the - * actual endpoints. More specifically, it is applied to the outgoing traffic - * from the proxy to the endpoint. This is typically used for sidecar model - * where the proxy identifies itself as endpoint to the control plane, with - * the connection between sidecar and endpoint requiring authentication. If - * this field is not set, authentication is disabled(open). Applicable only - * when EndpointPolicyType is SIDECAR_PROXY. - * - * Generated from protobuf field string client_tls_policy = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getClientTlsPolicy() - { - return $this->client_tls_policy; - } - - /** - * Optional. A URL referring to a ClientTlsPolicy resource. ClientTlsPolicy - * can be set to specify the authentication for traffic from the proxy to the - * actual endpoints. More specifically, it is applied to the outgoing traffic - * from the proxy to the endpoint. This is typically used for sidecar model - * where the proxy identifies itself as endpoint to the control plane, with - * the connection between sidecar and endpoint requiring authentication. If - * this field is not set, authentication is disabled(open). Applicable only - * when EndpointPolicyType is SIDECAR_PROXY. - * - * Generated from protobuf field string client_tls_policy = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setClientTlsPolicy($var) - { - GPBUtil::checkString($var, True); - $this->client_tls_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy/EndpointPolicyType.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy/EndpointPolicyType.php deleted file mode 100644 index 98d7dae9e798..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EndpointPolicy/EndpointPolicyType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.networkservices.v1.EndpointPolicy.EndpointPolicyType - */ -class EndpointPolicyType -{ - /** - * Default value. Must not be used. - * - * Generated from protobuf enum ENDPOINT_POLICY_TYPE_UNSPECIFIED = 0; - */ - const ENDPOINT_POLICY_TYPE_UNSPECIFIED = 0; - /** - * Represents a proxy deployed as a sidecar. - * - * Generated from protobuf enum SIDECAR_PROXY = 1; - */ - const SIDECAR_PROXY = 1; - /** - * Represents a proxyless gRPC backend. - * - * Generated from protobuf enum GRPC_SERVER = 2; - */ - const GRPC_SERVER = 2; - - private static $valueToName = [ - self::ENDPOINT_POLICY_TYPE_UNSPECIFIED => 'ENDPOINT_POLICY_TYPE_UNSPECIFIED', - self::SIDECAR_PROXY => 'SIDECAR_PROXY', - self::GRPC_SERVER => 'GRPC_SERVER', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(EndpointPolicyType::class, \Google\Cloud\NetworkServices\V1\EndpointPolicy_EndpointPolicyType::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EventType.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EventType.php deleted file mode 100644 index fd2bd9ecfea8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/EventType.php +++ /dev/null @@ -1,95 +0,0 @@ -google.cloud.networkservices.v1.EventType - */ -class EventType -{ - /** - * Unspecified value. Do not use. - * - * Generated from protobuf enum EVENT_TYPE_UNSPECIFIED = 0; - */ - const EVENT_TYPE_UNSPECIFIED = 0; - /** - * If included in `supported_events`, - * the extension is called when the HTTP request headers arrive. - * - * Generated from protobuf enum REQUEST_HEADERS = 1; - */ - const REQUEST_HEADERS = 1; - /** - * If included in `supported_events`, - * the extension is called when the HTTP request body arrives. - * - * Generated from protobuf enum REQUEST_BODY = 2; - */ - const REQUEST_BODY = 2; - /** - * If included in `supported_events`, - * the extension is called when the HTTP response headers arrive. - * - * Generated from protobuf enum RESPONSE_HEADERS = 3; - */ - const RESPONSE_HEADERS = 3; - /** - * If included in `supported_events`, - * the extension is called when the HTTP response body arrives. - * - * Generated from protobuf enum RESPONSE_BODY = 4; - */ - const RESPONSE_BODY = 4; - /** - * If included in `supported_events`, - * the extension is called when the HTTP request trailers arrives. - * - * Generated from protobuf enum REQUEST_TRAILERS = 5; - */ - const REQUEST_TRAILERS = 5; - /** - * If included in `supported_events`, - * the extension is called when the HTTP response trailers arrives. - * - * Generated from protobuf enum RESPONSE_TRAILERS = 6; - */ - const RESPONSE_TRAILERS = 6; - - private static $valueToName = [ - self::EVENT_TYPE_UNSPECIFIED => 'EVENT_TYPE_UNSPECIFIED', - self::REQUEST_HEADERS => 'REQUEST_HEADERS', - self::REQUEST_BODY => 'REQUEST_BODY', - self::RESPONSE_HEADERS => 'RESPONSE_HEADERS', - self::RESPONSE_BODY => 'RESPONSE_BODY', - self::REQUEST_TRAILERS => 'REQUEST_TRAILERS', - self::RESPONSE_TRAILERS => 'RESPONSE_TRAILERS', - ]; - - 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain.php deleted file mode 100644 index 4da12b6f0838..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.networkservices.v1.ExtensionChain - */ -class ExtensionChain extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name for this extension chain. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased letters, - * numbers and hyphens, and can have a maximum length of 63 characters. - * Additionally, the first character must be a letter and the last a letter or - * a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Required. Conditions under which this chain is invoked for a request. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ExtensionChain.MatchCondition match_condition = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $match_condition = null; - /** - * Required. A set of extensions to execute for the matching request. - * At least one extension is required. - * Up to 3 extensions can be defined for each extension chain - * for `LbTrafficExtension` resource. - * `LbRouteExtension` chains are limited to 1 extension per extension chain. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain.Extension extensions = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - private $extensions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name for this extension chain. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased letters, - * numbers and hyphens, and can have a maximum length of 63 characters. - * Additionally, the first character must be a letter and the last a letter or - * a number. - * @type \Google\Cloud\NetworkServices\V1\ExtensionChain\MatchCondition $match_condition - * Required. Conditions under which this chain is invoked for a request. - * @type array<\Google\Cloud\NetworkServices\V1\ExtensionChain\Extension>|\Google\Protobuf\Internal\RepeatedField $extensions - * Required. A set of extensions to execute for the matching request. - * At least one extension is required. - * Up to 3 extensions can be defined for each extension chain - * for `LbTrafficExtension` resource. - * `LbRouteExtension` chains are limited to 1 extension per extension chain. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name for this extension chain. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased letters, - * numbers and hyphens, and can have a maximum length of 63 characters. - * Additionally, the first character must be a letter and the last a letter or - * a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name for this extension chain. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased letters, - * numbers and hyphens, and can have a maximum length of 63 characters. - * Additionally, the first character must be a letter and the last a letter or - * a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Conditions under which this chain is invoked for a request. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ExtensionChain.MatchCondition match_condition = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\ExtensionChain\MatchCondition|null - */ - public function getMatchCondition() - { - return $this->match_condition; - } - - public function hasMatchCondition() - { - return isset($this->match_condition); - } - - public function clearMatchCondition() - { - unset($this->match_condition); - } - - /** - * Required. Conditions under which this chain is invoked for a request. - * - * Generated from protobuf field .google.cloud.networkservices.v1.ExtensionChain.MatchCondition match_condition = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\ExtensionChain\MatchCondition $var - * @return $this - */ - public function setMatchCondition($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\ExtensionChain\MatchCondition::class); - $this->match_condition = $var; - - return $this; - } - - /** - * Required. A set of extensions to execute for the matching request. - * At least one extension is required. - * Up to 3 extensions can be defined for each extension chain - * for `LbTrafficExtension` resource. - * `LbRouteExtension` chains are limited to 1 extension per extension chain. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain.Extension extensions = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExtensions() - { - return $this->extensions; - } - - /** - * Required. A set of extensions to execute for the matching request. - * At least one extension is required. - * Up to 3 extensions can be defined for each extension chain - * for `LbTrafficExtension` resource. - * `LbRouteExtension` chains are limited to 1 extension per extension chain. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain.Extension extensions = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\ExtensionChain\Extension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\ExtensionChain\Extension::class); - $this->extensions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/Extension.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/Extension.php deleted file mode 100644 index d2820bcd18b7..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/Extension.php +++ /dev/null @@ -1,416 +0,0 @@ -google.cloud.networkservices.v1.ExtensionChain.Extension - */ -class Extension extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name for this extension. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased - * letters, numbers and hyphens, and can have a maximum length of 63 - * characters. Additionally, the first character must be a letter and the - * last a letter or a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Optional. The `:authority` header in the gRPC request sent from Envoy - * to the extension service. - * Required for Callout extensions. - * - * Generated from protobuf field string authority = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $authority = ''; - /** - * Required. The reference to the service that runs the extension. - * Currently only callout extensions are supported here. - * To configure a callout extension, `service` must be a fully-qualified - * reference - * to a [backend - * service](https://cloud.google.com/compute/docs/reference/rest/v1/backendServices) - * in the format: - * `https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/backendServices/{backendService}` - * or - * `https://www.googleapis.com/compute/v1/projects/{project}/global/backendServices/{backendService}`. - * - * Generated from protobuf field string service = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service = ''; - /** - * Optional. A set of events during request or response processing for which - * this extension is called. This field is required for the - * `LbTrafficExtension` resource. It must not be set for the - * `LbRouteExtension` resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EventType supported_events = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $supported_events; - /** - * Optional. Specifies the timeout for each individual message on the - * stream. The timeout must be between 10-1000 milliseconds. Required for - * Callout extensions. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $timeout = null; - /** - * Optional. Determines how the proxy behaves if the call to the extension - * fails or times out. - * When set to `TRUE`, request or response processing continues without - * error. Any subsequent extensions in the extension chain are also - * executed. When set to `FALSE` or the default setting of `FALSE` is used, - * one of the following happens: - * * If response headers have not been delivered to the downstream client, - * a generic 500 error is returned to the client. The error response can be - * tailored by configuring a custom error response in the load balancer. - * * If response headers have been delivered, then the HTTP stream to the - * downstream client is reset. - * - * Generated from protobuf field bool fail_open = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $fail_open = false; - /** - * Optional. List of the HTTP headers to forward to the extension - * (from the client or backend). If omitted, all headers are sent. - * Each element is a string indicating the header name. - * - * Generated from protobuf field repeated string forward_headers = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $forward_headers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name for this extension. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased - * letters, numbers and hyphens, and can have a maximum length of 63 - * characters. Additionally, the first character must be a letter and the - * last a letter or a number. - * @type string $authority - * Optional. The `:authority` header in the gRPC request sent from Envoy - * to the extension service. - * Required for Callout extensions. - * @type string $service - * Required. The reference to the service that runs the extension. - * Currently only callout extensions are supported here. - * To configure a callout extension, `service` must be a fully-qualified - * reference - * to a [backend - * service](https://cloud.google.com/compute/docs/reference/rest/v1/backendServices) - * in the format: - * `https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/backendServices/{backendService}` - * or - * `https://www.googleapis.com/compute/v1/projects/{project}/global/backendServices/{backendService}`. - * @type array|\Google\Protobuf\Internal\RepeatedField $supported_events - * Optional. A set of events during request or response processing for which - * this extension is called. This field is required for the - * `LbTrafficExtension` resource. It must not be set for the - * `LbRouteExtension` resource. - * @type \Google\Protobuf\Duration $timeout - * Optional. Specifies the timeout for each individual message on the - * stream. The timeout must be between 10-1000 milliseconds. Required for - * Callout extensions. - * @type bool $fail_open - * Optional. Determines how the proxy behaves if the call to the extension - * fails or times out. - * When set to `TRUE`, request or response processing continues without - * error. Any subsequent extensions in the extension chain are also - * executed. When set to `FALSE` or the default setting of `FALSE` is used, - * one of the following happens: - * * If response headers have not been delivered to the downstream client, - * a generic 500 error is returned to the client. The error response can be - * tailored by configuring a custom error response in the load balancer. - * * If response headers have been delivered, then the HTTP stream to the - * downstream client is reset. - * @type array|\Google\Protobuf\Internal\RepeatedField $forward_headers - * Optional. List of the HTTP headers to forward to the extension - * (from the client or backend). If omitted, all headers are sent. - * Each element is a string indicating the header name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name for this extension. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased - * letters, numbers and hyphens, and can have a maximum length of 63 - * characters. Additionally, the first character must be a letter and the - * last a letter or a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name for this extension. - * The name is logged as part of the HTTP request logs. - * The name must conform with RFC-1034, is restricted to lower-cased - * letters, numbers and hyphens, and can have a maximum length of 63 - * characters. Additionally, the first character must be a letter and the - * last a letter or a number. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The `:authority` header in the gRPC request sent from Envoy - * to the extension service. - * Required for Callout extensions. - * - * Generated from protobuf field string authority = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getAuthority() - { - return $this->authority; - } - - /** - * Optional. The `:authority` header in the gRPC request sent from Envoy - * to the extension service. - * Required for Callout extensions. - * - * Generated from protobuf field string authority = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setAuthority($var) - { - GPBUtil::checkString($var, True); - $this->authority = $var; - - return $this; - } - - /** - * Required. The reference to the service that runs the extension. - * Currently only callout extensions are supported here. - * To configure a callout extension, `service` must be a fully-qualified - * reference - * to a [backend - * service](https://cloud.google.com/compute/docs/reference/rest/v1/backendServices) - * in the format: - * `https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/backendServices/{backendService}` - * or - * `https://www.googleapis.com/compute/v1/projects/{project}/global/backendServices/{backendService}`. - * - * Generated from protobuf field string service = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * Required. The reference to the service that runs the extension. - * Currently only callout extensions are supported here. - * To configure a callout extension, `service` must be a fully-qualified - * reference - * to a [backend - * service](https://cloud.google.com/compute/docs/reference/rest/v1/backendServices) - * in the format: - * `https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/backendServices/{backendService}` - * or - * `https://www.googleapis.com/compute/v1/projects/{project}/global/backendServices/{backendService}`. - * - * Generated from protobuf field string service = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * Optional. A set of events during request or response processing for which - * this extension is called. This field is required for the - * `LbTrafficExtension` resource. It must not be set for the - * `LbRouteExtension` resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EventType supported_events = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSupportedEvents() - { - return $this->supported_events; - } - - /** - * Optional. A set of events during request or response processing for which - * this extension is called. This field is required for the - * `LbTrafficExtension` resource. It must not be set for the - * `LbRouteExtension` resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EventType supported_events = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSupportedEvents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\NetworkServices\V1\EventType::class); - $this->supported_events = $arr; - - return $this; - } - - /** - * Optional. Specifies the timeout for each individual message on the - * stream. The timeout must be between 10-1000 milliseconds. Required for - * Callout extensions. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Optional. Specifies the timeout for each individual message on the - * stream. The timeout must be between 10-1000 milliseconds. Required for - * Callout extensions. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * Optional. Determines how the proxy behaves if the call to the extension - * fails or times out. - * When set to `TRUE`, request or response processing continues without - * error. Any subsequent extensions in the extension chain are also - * executed. When set to `FALSE` or the default setting of `FALSE` is used, - * one of the following happens: - * * If response headers have not been delivered to the downstream client, - * a generic 500 error is returned to the client. The error response can be - * tailored by configuring a custom error response in the load balancer. - * * If response headers have been delivered, then the HTTP stream to the - * downstream client is reset. - * - * Generated from protobuf field bool fail_open = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getFailOpen() - { - return $this->fail_open; - } - - /** - * Optional. Determines how the proxy behaves if the call to the extension - * fails or times out. - * When set to `TRUE`, request or response processing continues without - * error. Any subsequent extensions in the extension chain are also - * executed. When set to `FALSE` or the default setting of `FALSE` is used, - * one of the following happens: - * * If response headers have not been delivered to the downstream client, - * a generic 500 error is returned to the client. The error response can be - * tailored by configuring a custom error response in the load balancer. - * * If response headers have been delivered, then the HTTP stream to the - * downstream client is reset. - * - * Generated from protobuf field bool fail_open = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setFailOpen($var) - { - GPBUtil::checkBool($var); - $this->fail_open = $var; - - return $this; - } - - /** - * Optional. List of the HTTP headers to forward to the extension - * (from the client or backend). If omitted, all headers are sent. - * Each element is a string indicating the header name. - * - * Generated from protobuf field repeated string forward_headers = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getForwardHeaders() - { - return $this->forward_headers; - } - - /** - * Optional. List of the HTTP headers to forward to the extension - * (from the client or backend). If omitted, all headers are sent. - * Each element is a string indicating the header name. - * - * Generated from protobuf field repeated string forward_headers = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setForwardHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->forward_headers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Extension::class, \Google\Cloud\NetworkServices\V1\ExtensionChain_Extension::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/MatchCondition.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/MatchCondition.php deleted file mode 100644 index b6cffb76dc23..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ExtensionChain/MatchCondition.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.networkservices.v1.ExtensionChain.MatchCondition - */ -class MatchCondition extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A Common Expression Language (CEL) expression that is used to - * match requests for which the extension chain is executed. - * For more information, see [CEL matcher language - * reference](https://cloud.google.com/service-extensions/docs/cel-matcher-language-reference). - * - * Generated from protobuf field string cel_expression = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cel_expression = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cel_expression - * Required. A Common Expression Language (CEL) expression that is used to - * match requests for which the extension chain is executed. - * For more information, see [CEL matcher language - * reference](https://cloud.google.com/service-extensions/docs/cel-matcher-language-reference). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. A Common Expression Language (CEL) expression that is used to - * match requests for which the extension chain is executed. - * For more information, see [CEL matcher language - * reference](https://cloud.google.com/service-extensions/docs/cel-matcher-language-reference). - * - * Generated from protobuf field string cel_expression = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCelExpression() - { - return $this->cel_expression; - } - - /** - * Required. A Common Expression Language (CEL) expression that is used to - * match requests for which the extension chain is executed. - * For more information, see [CEL matcher language - * reference](https://cloud.google.com/service-extensions/docs/cel-matcher-language-reference). - * - * Generated from protobuf field string cel_expression = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCelExpression($var) - { - GPBUtil::checkString($var, True); - $this->cel_expression = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MatchCondition::class, \Google\Cloud\NetworkServices\V1\ExtensionChain_MatchCondition::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway.php deleted file mode 100644 index 234827599ae4..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway.php +++ /dev/null @@ -1,444 +0,0 @@ -google.cloud.networkservices.v1.Gateway - */ -class Gateway extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the Gateway resource. It matches pattern - * `projects/*/locations/*/gateways/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Set of label tags associated with the Gateway resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Immutable. The type of the customer managed gateway. - * This field is required. If unspecified, an error is returned. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway.Type type = 6 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $type = 0; - /** - * Required. One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * - * Generated from protobuf field repeated int32 ports = 11 [(.google.api.field_behavior) = REQUIRED]; - */ - private $ports; - /** - * Required. Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - * - * Generated from protobuf field string scope = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $scope = ''; - /** - * Optional. A fully-qualified ServerTLSPolicy URL reference. Specifies how - * TLS traffic is terminated. If empty, TLS termination is disabled. - * - * Generated from protobuf field string server_tls_policy = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $server_tls_policy = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the Gateway resource. It matches pattern - * `projects/*/locations/*/gateways/`. - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the Gateway resource. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type int $type - * Immutable. The type of the customer managed gateway. - * This field is required. If unspecified, an error is returned. - * @type array|\Google\Protobuf\Internal\RepeatedField $ports - * Required. One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * @type string $scope - * Required. Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - * @type string $server_tls_policy - * Optional. A fully-qualified ServerTLSPolicy URL reference. Specifies how - * TLS traffic is terminated. If empty, TLS termination is disabled. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the Gateway resource. It matches pattern - * `projects/*/locations/*/gateways/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the Gateway resource. It matches pattern - * `projects/*/locations/*/gateways/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. Set of label tags associated with the Gateway resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the Gateway resource. - * - * 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. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * 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; - } - - /** - * Immutable. The type of the customer managed gateway. - * This field is required. If unspecified, an error is returned. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway.Type type = 6 [(.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Immutable. The type of the customer managed gateway. - * This field is required. If unspecified, an error is returned. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway.Type type = 6 [(.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\Gateway\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * - * Generated from protobuf field repeated int32 ports = 11 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPorts() - { - return $this->ports; - } - - /** - * Required. One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * - * Generated from protobuf field repeated int32 ports = 11 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->ports = $arr; - - return $this; - } - - /** - * Required. Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - * - * Generated from protobuf field string scope = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getScope() - { - return $this->scope; - } - - /** - * Required. Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - * - * Generated from protobuf field string scope = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkString($var, True); - $this->scope = $var; - - return $this; - } - - /** - * Optional. A fully-qualified ServerTLSPolicy URL reference. Specifies how - * TLS traffic is terminated. If empty, TLS termination is disabled. - * - * Generated from protobuf field string server_tls_policy = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getServerTlsPolicy() - { - return $this->server_tls_policy; - } - - /** - * Optional. A fully-qualified ServerTLSPolicy URL reference. Specifies how - * TLS traffic is terminated. If empty, TLS termination is disabled. - * - * Generated from protobuf field string server_tls_policy = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setServerTlsPolicy($var) - { - GPBUtil::checkString($var, True); - $this->server_tls_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway/Type.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway/Type.php deleted file mode 100644 index 94d7aa0e2f27..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Gateway/Type.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.networkservices.v1.Gateway.Type - */ -class Type -{ - /** - * The type of the customer managed gateway is unspecified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * The type of the customer managed gateway is TrafficDirector Open - * Mesh. - * - * Generated from protobuf enum OPEN_MESH = 1; - */ - const OPEN_MESH = 1; - /** - * The type of the customer managed gateway is SecureWebGateway (SWG). - * - * Generated from protobuf enum SECURE_WEB_GATEWAY = 2; - */ - const SECURE_WEB_GATEWAY = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::OPEN_MESH => 'OPEN_MESH', - self::SECURE_WEB_GATEWAY => 'SECURE_WEB_GATEWAY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\NetworkServices\V1\Gateway_Type::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetEndpointPolicyRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetEndpointPolicyRequest.php deleted file mode 100644 index 185d8ae98028..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetEndpointPolicyRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetEndpointPolicyRequest - */ -class GetEndpointPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the EndpointPolicy to get. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * 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. A name of the EndpointPolicy to get. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the EndpointPolicy to get. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the EndpointPolicy to get. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGatewayRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGatewayRequest.php deleted file mode 100644 index 94c1dd152792..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGatewayRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetGatewayRequest - */ -class GetGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the Gateway to get. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * 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. A name of the Gateway to get. Must be in the format - * `projects/*/locations/*/gateways/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the Gateway to get. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the Gateway to get. Must be in the format - * `projects/*/locations/*/gateways/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGrpcRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGrpcRouteRequest.php deleted file mode 100644 index a78e9293575a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetGrpcRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetGrpcRouteRequest - */ -class GetGrpcRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the GrpcRoute to get. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * 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. A name of the GrpcRoute to get. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the GrpcRoute to get. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the GrpcRoute to get. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetHttpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetHttpRouteRequest.php deleted file mode 100644 index 6a0950a4ae8a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetHttpRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetHttpRouteRequest - */ -class GetHttpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the HttpRoute to get. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * 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. A name of the HttpRoute to get. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the HttpRoute to get. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the HttpRoute to get. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbRouteExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbRouteExtensionRequest.php deleted file mode 100644 index 8392a00c0eb2..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbRouteExtensionRequest.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.networkservices.v1.GetLbRouteExtensionRequest - */ -class GetLbRouteExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the `LbRouteExtension` resource to get. Must be in the - * format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * 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. A name of the `LbRouteExtension` resource to get. Must be in the - * format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the `LbRouteExtension` resource to get. Must be in the - * format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the `LbRouteExtension` resource to get. Must be in the - * format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbTrafficExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbTrafficExtensionRequest.php deleted file mode 100644 index c8ddafef9721..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetLbTrafficExtensionRequest.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.networkservices.v1.GetLbTrafficExtensionRequest - */ -class GetLbTrafficExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the `LbTrafficExtension` resource to get. Must be in - * the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * 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. A name of the `LbTrafficExtension` resource to get. Must be in - * the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the `LbTrafficExtension` resource to get. Must be in - * the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the `LbTrafficExtension` resource to get. Must be in - * the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetMeshRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetMeshRequest.php deleted file mode 100644 index 268a9a24efca..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetMeshRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetMeshRequest - */ -class GetMeshRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the Mesh to get. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * 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. A name of the Mesh to get. Must be in the format - * `projects/*/locations/global/meshes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the Mesh to get. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the Mesh to get. Must be in the format - * `projects/*/locations/global/meshes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetServiceBindingRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetServiceBindingRequest.php deleted file mode 100644 index 36a12ec1ce97..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetServiceBindingRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetServiceBindingRequest - */ -class GetServiceBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the ServiceBinding to get. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * 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. A name of the ServiceBinding to get. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the ServiceBinding to get. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the ServiceBinding to get. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTcpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTcpRouteRequest.php deleted file mode 100644 index 9fc56eba0b6a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTcpRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetTcpRouteRequest - */ -class GetTcpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the TcpRoute to get. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * 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. A name of the TcpRoute to get. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the TcpRoute to get. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the TcpRoute to get. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTlsRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTlsRouteRequest.php deleted file mode 100644 index 89e92b962a86..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GetTlsRouteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.networkservices.v1.GetTlsRouteRequest - */ -class GetTlsRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the TlsRoute to get. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * 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. A name of the TlsRoute to get. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the TlsRoute to get. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the TlsRoute to get. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute.php deleted file mode 100644 index 2404004aec76..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute.php +++ /dev/null @@ -1,534 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute - */ -class GrpcRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the GrpcRoute resource. It matches pattern - * `projects/*/locations/global/grpcRoutes/` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Set of label tags associated with the GrpcRoute resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Required. Service hostnames with an optional port for which this route - * describes traffic. - * Format: [:] - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - * - * Generated from protobuf field repeated string hostnames = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - private $hostnames; - /** - * Optional. Meshes defines a list of meshes this GrpcRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * - * Generated from protobuf field repeated string meshes = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $meshes; - /** - * Optional. Gateways defines a list of gateways this GrpcRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 10 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $gateways; - /** - * Required. A list of detailed rules defining how to route traffic. - * Within a single GrpcRoute, the GrpcRoute.RouteAction associated with the - * first matching GrpcRoute.RouteRule will be executed. At least one rule - * must be supplied. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteRule rules = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - private $rules; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the GrpcRoute resource. It matches pattern - * `projects/*/locations/global/grpcRoutes/` - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the GrpcRoute resource. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type array|\Google\Protobuf\Internal\RepeatedField $hostnames - * Required. Service hostnames with an optional port for which this route - * describes traffic. - * Format: [:] - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - * @type array|\Google\Protobuf\Internal\RepeatedField $meshes - * Optional. Meshes defines a list of meshes this GrpcRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * @type array|\Google\Protobuf\Internal\RepeatedField $gateways - * Optional. Gateways defines a list of gateways this GrpcRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * @type array<\Google\Cloud\NetworkServices\V1\GrpcRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $rules - * Required. A list of detailed rules defining how to route traffic. - * Within a single GrpcRoute, the GrpcRoute.RouteAction associated with the - * first matching GrpcRoute.RouteRule will be executed. At least one rule - * must be supplied. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the GrpcRoute resource. It matches pattern - * `projects/*/locations/global/grpcRoutes/` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the GrpcRoute resource. It matches pattern - * `projects/*/locations/global/grpcRoutes/` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. Set of label tags associated with the GrpcRoute resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the GrpcRoute resource. - * - * 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. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * 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; - } - - /** - * Required. Service hostnames with an optional port for which this route - * describes traffic. - * Format: [:] - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - * - * Generated from protobuf field repeated string hostnames = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHostnames() - { - return $this->hostnames; - } - - /** - * Required. Service hostnames with an optional port for which this route - * describes traffic. - * Format: [:] - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - * - * Generated from protobuf field repeated string hostnames = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHostnames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->hostnames = $arr; - - return $this; - } - - /** - * Optional. Meshes defines a list of meshes this GrpcRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * - * Generated from protobuf field repeated string meshes = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMeshes() - { - return $this->meshes; - } - - /** - * Optional. Meshes defines a list of meshes this GrpcRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * - * Generated from protobuf field repeated string meshes = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMeshes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->meshes = $arr; - - return $this; - } - - /** - * Optional. Gateways defines a list of gateways this GrpcRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 10 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGateways() - { - return $this->gateways; - } - - /** - * Optional. Gateways defines a list of gateways this GrpcRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 10 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->gateways = $arr; - - return $this; - } - - /** - * Required. A list of detailed rules defining how to route traffic. - * Within a single GrpcRoute, the GrpcRoute.RouteAction associated with the - * first matching GrpcRoute.RouteRule will be executed. At least one rule - * must be supplied. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteRule rules = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRules() - { - return $this->rules; - } - - /** - * Required. A list of detailed rules defining how to route traffic. - * Within a single GrpcRoute, the GrpcRoute.RouteAction associated with the - * first matching GrpcRoute.RouteRule will be executed. At least one rule - * must be supplied. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteRule rules = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\GrpcRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteRule::class); - $this->rules = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/Destination.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/Destination.php deleted file mode 100644 index 97af98df7e7b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/Destination.php +++ /dev/null @@ -1,165 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.Destination - */ -class Destination extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field optional int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $weight = null; - protected $destination_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The URL of a destination service to which to route traffic. - * Must refer to either a BackendService or ServiceDirectoryService. - * @type int $weight - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The URL of a destination service to which to route traffic. - * Must refer to either a BackendService or ServiceDirectoryService. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getServiceName() - { - return $this->readOneof(1); - } - - public function hasServiceName() - { - return $this->hasOneof(1); - } - - /** - * Required. The URL of a destination service to which to route traffic. - * Must refer to either a BackendService or ServiceDirectoryService. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field optional int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getWeight() - { - return isset($this->weight) ? $this->weight : 0; - } - - public function hasWeight() - { - return isset($this->weight); - } - - public function clearWeight() - { - unset($this->weight); - } - - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field optional int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setWeight($var) - { - GPBUtil::checkInt32($var); - $this->weight = $var; - - return $this; - } - - /** - * @return string - */ - public function getDestinationType() - { - return $this->whichOneof("destination_type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Destination::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_Destination::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy.php deleted file mode 100644 index 57b6a7b3da3a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy.php +++ /dev/null @@ -1,129 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy - */ -class FaultInjectionPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Delay delay = 1; - */ - protected $delay = null; - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Abort abort = 2; - */ - protected $abort = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Delay $delay - * The specification for injecting delay to client requests. - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Abort $abort - * The specification for aborting to client requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Delay delay = 1; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Delay|null - */ - public function getDelay() - { - return $this->delay; - } - - public function hasDelay() - { - return isset($this->delay); - } - - public function clearDelay() - { - unset($this->delay); - } - - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Delay delay = 1; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Delay $var - * @return $this - */ - public function setDelay($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Delay::class); - $this->delay = $var; - - return $this; - } - - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Abort abort = 2; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Abort|null - */ - public function getAbort() - { - return $this->abort; - } - - public function hasAbort() - { - return isset($this->abort); - } - - public function clearAbort() - { - unset($this->abort); - } - - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Abort abort = 2; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Abort $var - * @return $this - */ - public function setAbort($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy\Abort::class); - $this->abort = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FaultInjectionPolicy::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_FaultInjectionPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Abort.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Abort.php deleted file mode 100644 index fbbfc30a96a4..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Abort.php +++ /dev/null @@ -1,133 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Abort - */ -class Abort extends \Google\Protobuf\Internal\Message -{ - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field optional int32 http_status = 1; - */ - protected $http_status = null; - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - */ - protected $percentage = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $http_status - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * @type int $percentage - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field optional int32 http_status = 1; - * @return int - */ - public function getHttpStatus() - { - return isset($this->http_status) ? $this->http_status : 0; - } - - public function hasHttpStatus() - { - return isset($this->http_status); - } - - public function clearHttpStatus() - { - unset($this->http_status); - } - - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field optional int32 http_status = 1; - * @param int $var - * @return $this - */ - public function setHttpStatus($var) - { - GPBUtil::checkInt32($var); - $this->http_status = $var; - - return $this; - } - - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - * @return int - */ - public function getPercentage() - { - return isset($this->percentage) ? $this->percentage : 0; - } - - public function hasPercentage() - { - return isset($this->percentage); - } - - public function clearPercentage() - { - unset($this->percentage); - } - - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - * @param int $var - * @return $this - */ - public function setPercentage($var) - { - GPBUtil::checkInt32($var); - $this->percentage = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Abort::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_FaultInjectionPolicy_Abort::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Delay.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Delay.php deleted file mode 100644 index e36e4c35da19..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/FaultInjectionPolicy/Delay.php +++ /dev/null @@ -1,129 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy.Delay - */ -class Delay extends \Google\Protobuf\Internal\Message -{ - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field optional .google.protobuf.Duration fixed_delay = 1; - */ - protected $fixed_delay = null; - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - */ - protected $percentage = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Duration $fixed_delay - * Specify a fixed delay before forwarding the request. - * @type int $percentage - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field optional .google.protobuf.Duration fixed_delay = 1; - * @return \Google\Protobuf\Duration|null - */ - public function getFixedDelay() - { - return $this->fixed_delay; - } - - public function hasFixedDelay() - { - return isset($this->fixed_delay); - } - - public function clearFixedDelay() - { - unset($this->fixed_delay); - } - - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field optional .google.protobuf.Duration fixed_delay = 1; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setFixedDelay($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->fixed_delay = $var; - - return $this; - } - - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - * @return int - */ - public function getPercentage() - { - return isset($this->percentage) ? $this->percentage : 0; - } - - public function hasPercentage() - { - return isset($this->percentage); - } - - public function clearPercentage() - { - unset($this->percentage); - } - - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field optional int32 percentage = 2; - * @param int $var - * @return $this - */ - public function setPercentage($var) - { - GPBUtil::checkInt32($var); - $this->percentage = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Delay::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_FaultInjectionPolicy_Delay::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch.php deleted file mode 100644 index f66b13869032..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.HeaderMatch - */ -class HeaderMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Specifies how to match against the value of the header. If not - * specified, a default value of EXACT is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $type = 0; - /** - * Required. The key of the header. - * - * Generated from protobuf field string key = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key = ''; - /** - * Required. The value of the header. - * - * Generated from protobuf field string value = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * Optional. Specifies how to match against the value of the header. If not - * specified, a default value of EXACT is used. - * @type string $key - * Required. The key of the header. - * @type string $value - * Required. The value of the header. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Specifies how to match against the value of the header. If not - * specified, a default value of EXACT is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Optional. Specifies how to match against the value of the header. If not - * specified, a default value of EXACT is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\HeaderMatch\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. The key of the header. - * - * Generated from protobuf field string key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getKey() - { - return $this->key; - } - - /** - * Required. The key of the header. - * - * Generated from protobuf field string key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkString($var, True); - $this->key = $var; - - return $this; - } - - /** - * Required. The value of the header. - * - * Generated from protobuf field string value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * Required. The value of the header. - * - * Generated from protobuf field string value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HeaderMatch::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_HeaderMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch/Type.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch/Type.php deleted file mode 100644 index 488ce2d6f01c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/HeaderMatch/Type.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.HeaderMatch.Type - */ -class Type -{ - /** - * Unspecified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Will only match the exact value provided. - * - * Generated from protobuf enum EXACT = 1; - */ - const EXACT = 1; - /** - * Will match paths conforming to the prefix specified by value. RE2 - * syntax is supported. - * - * Generated from protobuf enum REGULAR_EXPRESSION = 2; - */ - const REGULAR_EXPRESSION = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::EXACT => 'EXACT', - self::REGULAR_EXPRESSION => 'REGULAR_EXPRESSION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_HeaderMatch_Type::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch.php deleted file mode 100644 index 6fe009dd5e9e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch.php +++ /dev/null @@ -1,202 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.MethodMatch - */ -class MethodMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Specifies how to match against the name. If not specified, a - * default value of "EXACT" is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.MethodMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $type = 0; - /** - * Required. Name of the service to match against. If unspecified, will - * match all services. - * - * Generated from protobuf field string grpc_service = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $grpc_service = ''; - /** - * Required. Name of the method to match against. If unspecified, will match - * all methods. - * - * Generated from protobuf field string grpc_method = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $grpc_method = ''; - /** - * Optional. Specifies that matches are case sensitive. The default value - * is true. case_sensitive must not be used with a type of - * REGULAR_EXPRESSION. - * - * Generated from protobuf field optional bool case_sensitive = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $case_sensitive = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * Optional. Specifies how to match against the name. If not specified, a - * default value of "EXACT" is used. - * @type string $grpc_service - * Required. Name of the service to match against. If unspecified, will - * match all services. - * @type string $grpc_method - * Required. Name of the method to match against. If unspecified, will match - * all methods. - * @type bool $case_sensitive - * Optional. Specifies that matches are case sensitive. The default value - * is true. case_sensitive must not be used with a type of - * REGULAR_EXPRESSION. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Specifies how to match against the name. If not specified, a - * default value of "EXACT" is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.MethodMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Optional. Specifies how to match against the name. If not specified, a - * default value of "EXACT" is used. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.MethodMatch.Type type = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\MethodMatch\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. Name of the service to match against. If unspecified, will - * match all services. - * - * Generated from protobuf field string grpc_service = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGrpcService() - { - return $this->grpc_service; - } - - /** - * Required. Name of the service to match against. If unspecified, will - * match all services. - * - * Generated from protobuf field string grpc_service = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGrpcService($var) - { - GPBUtil::checkString($var, True); - $this->grpc_service = $var; - - return $this; - } - - /** - * Required. Name of the method to match against. If unspecified, will match - * all methods. - * - * Generated from protobuf field string grpc_method = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGrpcMethod() - { - return $this->grpc_method; - } - - /** - * Required. Name of the method to match against. If unspecified, will match - * all methods. - * - * Generated from protobuf field string grpc_method = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGrpcMethod($var) - { - GPBUtil::checkString($var, True); - $this->grpc_method = $var; - - return $this; - } - - /** - * Optional. Specifies that matches are case sensitive. The default value - * is true. case_sensitive must not be used with a type of - * REGULAR_EXPRESSION. - * - * Generated from protobuf field optional bool case_sensitive = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getCaseSensitive() - { - return isset($this->case_sensitive) ? $this->case_sensitive : false; - } - - public function hasCaseSensitive() - { - return isset($this->case_sensitive); - } - - public function clearCaseSensitive() - { - unset($this->case_sensitive); - } - - /** - * Optional. Specifies that matches are case sensitive. The default value - * is true. case_sensitive must not be used with a type of - * REGULAR_EXPRESSION. - * - * Generated from protobuf field optional bool case_sensitive = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MethodMatch::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_MethodMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch/Type.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch/Type.php deleted file mode 100644 index cbef63937f7f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/MethodMatch/Type.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.MethodMatch.Type - */ -class Type -{ - /** - * Unspecified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Will only match the exact name provided. - * - * Generated from protobuf enum EXACT = 1; - */ - const EXACT = 1; - /** - * Will interpret grpc_method and grpc_service as regexes. RE2 syntax is - * supported. - * - * Generated from protobuf enum REGULAR_EXPRESSION = 2; - */ - const REGULAR_EXPRESSION = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::EXACT => 'EXACT', - self::REGULAR_EXPRESSION => 'REGULAR_EXPRESSION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_MethodMatch_Type::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RetryPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RetryPolicy.php deleted file mode 100644 index cd34c9523201..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RetryPolicy.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.RetryPolicy - */ -class RetryPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * - connect-failure: Router will retry on failures connecting to Backend - * Services, for example due to connection timeouts. - * - refused-stream: Router will retry if the backend service resets the - * stream - * with a REFUSED_STREAM error code. This reset type indicates that it is - * safe to retry. - * - cancelled: Router will retry if the gRPC status code in the response - * header - * is set to cancelled - * - deadline-exceeded: Router will retry if the gRPC status code in the - * response - * header is set to deadline-exceeded - * - resource-exhausted: Router will retry if the gRPC status code in the - * response header is set to resource-exhausted - * - unavailable: Router will retry if the gRPC status code in the response - * header is set to unavailable - * - * Generated from protobuf field repeated string retry_conditions = 1; - */ - private $retry_conditions; - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field uint32 num_retries = 2; - */ - protected $num_retries = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $retry_conditions - * - connect-failure: Router will retry on failures connecting to Backend - * Services, for example due to connection timeouts. - * - refused-stream: Router will retry if the backend service resets the - * stream - * with a REFUSED_STREAM error code. This reset type indicates that it is - * safe to retry. - * - cancelled: Router will retry if the gRPC status code in the response - * header - * is set to cancelled - * - deadline-exceeded: Router will retry if the gRPC status code in the - * response - * header is set to deadline-exceeded - * - resource-exhausted: Router will retry if the gRPC status code in the - * response header is set to resource-exhausted - * - unavailable: Router will retry if the gRPC status code in the response - * header is set to unavailable - * @type int $num_retries - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * - connect-failure: Router will retry on failures connecting to Backend - * Services, for example due to connection timeouts. - * - refused-stream: Router will retry if the backend service resets the - * stream - * with a REFUSED_STREAM error code. This reset type indicates that it is - * safe to retry. - * - cancelled: Router will retry if the gRPC status code in the response - * header - * is set to cancelled - * - deadline-exceeded: Router will retry if the gRPC status code in the - * response - * header is set to deadline-exceeded - * - resource-exhausted: Router will retry if the gRPC status code in the - * response header is set to resource-exhausted - * - unavailable: Router will retry if the gRPC status code in the response - * header is set to unavailable - * - * Generated from protobuf field repeated string retry_conditions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRetryConditions() - { - return $this->retry_conditions; - } - - /** - * - connect-failure: Router will retry on failures connecting to Backend - * Services, for example due to connection timeouts. - * - refused-stream: Router will retry if the backend service resets the - * stream - * with a REFUSED_STREAM error code. This reset type indicates that it is - * safe to retry. - * - cancelled: Router will retry if the gRPC status code in the response - * header - * is set to cancelled - * - deadline-exceeded: Router will retry if the gRPC status code in the - * response - * header is set to deadline-exceeded - * - resource-exhausted: Router will retry if the gRPC status code in the - * response header is set to resource-exhausted - * - unavailable: Router will retry if the gRPC status code in the response - * header is set to unavailable - * - * Generated from protobuf field repeated string retry_conditions = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRetryConditions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->retry_conditions = $arr; - - return $this; - } - - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field uint32 num_retries = 2; - * @return int - */ - public function getNumRetries() - { - return $this->num_retries; - } - - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field uint32 num_retries = 2; - * @param int $var - * @return $this - */ - public function setNumRetries($var) - { - GPBUtil::checkUint32($var); - $this->num_retries = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RetryPolicy::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_RetryPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteAction.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteAction.php deleted file mode 100644 index dfc6a40eb1b7..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteAction.php +++ /dev/null @@ -1,250 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.RouteAction - */ -class RouteAction extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The destination services to which traffic should be forwarded. - * If multiple destinations are specified, traffic will be split between - * Backend Service(s) according to the weight field of these destinations. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.Destination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $destinations; - /** - * Optional. The specification for fault injection introduced into traffic to test the - * resiliency of clients to destination service failure. As part of fault - * injection, when clients send requests to a destination, delays can be - * introduced on a percentage of requests before sending those requests to - * the destination service. Similarly requests from clients can be aborted - * by for a percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy fault_injection_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $fault_injection_policy = null; - /** - * Optional. Specifies the timeout for selected route. Timeout is computed - * from the time the request has been fully processed (i.e. end of stream) - * up until the response has been completely processed. Timeout includes all - * retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $timeout = null; - /** - * Optional. Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RetryPolicy retry_policy = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $retry_policy = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\GrpcRoute\Destination>|\Google\Protobuf\Internal\RepeatedField $destinations - * Optional. The destination services to which traffic should be forwarded. - * If multiple destinations are specified, traffic will be split between - * Backend Service(s) according to the weight field of these destinations. - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy $fault_injection_policy - * Optional. The specification for fault injection introduced into traffic to test the - * resiliency of clients to destination service failure. As part of fault - * injection, when clients send requests to a destination, delays can be - * introduced on a percentage of requests before sending those requests to - * the destination service. Similarly requests from clients can be aborted - * by for a percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * @type \Google\Protobuf\Duration $timeout - * Optional. Specifies the timeout for selected route. Timeout is computed - * from the time the request has been fully processed (i.e. end of stream) - * up until the response has been completely processed. Timeout includes all - * retries. - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\RetryPolicy $retry_policy - * Optional. Specifies the retry policy associated with this route. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The destination services to which traffic should be forwarded. - * If multiple destinations are specified, traffic will be split between - * Backend Service(s) according to the weight field of these destinations. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.Destination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDestinations() - { - return $this->destinations; - } - - /** - * Optional. The destination services to which traffic should be forwarded. - * If multiple destinations are specified, traffic will be split between - * Backend Service(s) according to the weight field of these destinations. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.Destination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\NetworkServices\V1\GrpcRoute\Destination>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDestinations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\GrpcRoute\Destination::class); - $this->destinations = $arr; - - return $this; - } - - /** - * Optional. The specification for fault injection introduced into traffic to test the - * resiliency of clients to destination service failure. As part of fault - * injection, when clients send requests to a destination, delays can be - * introduced on a percentage of requests before sending those requests to - * the destination service. Similarly requests from clients can be aborted - * by for a percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy fault_injection_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy|null - */ - public function getFaultInjectionPolicy() - { - return $this->fault_injection_policy; - } - - public function hasFaultInjectionPolicy() - { - return isset($this->fault_injection_policy); - } - - public function clearFaultInjectionPolicy() - { - unset($this->fault_injection_policy); - } - - /** - * Optional. The specification for fault injection introduced into traffic to test the - * resiliency of clients to destination service failure. As part of fault - * injection, when clients send requests to a destination, delays can be - * introduced on a percentage of requests before sending those requests to - * the destination service. Similarly requests from clients can be aborted - * by for a percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.FaultInjectionPolicy fault_injection_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy $var - * @return $this - */ - public function setFaultInjectionPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\FaultInjectionPolicy::class); - $this->fault_injection_policy = $var; - - return $this; - } - - /** - * Optional. Specifies the timeout for selected route. Timeout is computed - * from the time the request has been fully processed (i.e. end of stream) - * up until the response has been completely processed. Timeout includes all - * retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Optional. Specifies the timeout for selected route. Timeout is computed - * from the time the request has been fully processed (i.e. end of stream) - * up until the response has been completely processed. Timeout includes all - * retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * Optional. Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RetryPolicy retry_policy = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\RetryPolicy|null - */ - public function getRetryPolicy() - { - return $this->retry_policy; - } - - public function hasRetryPolicy() - { - return isset($this->retry_policy); - } - - public function clearRetryPolicy() - { - unset($this->retry_policy); - } - - /** - * Optional. Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RetryPolicy retry_policy = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\RetryPolicy $var - * @return $this - */ - public function setRetryPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\RetryPolicy::class); - $this->retry_policy = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteAction::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_RouteAction::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteMatch.php deleted file mode 100644 index 4dd41c36b91b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteMatch.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.RouteMatch - */ -class RouteMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A gRPC method to match against. If this field is empty or - * omitted, will match all methods. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.MethodMatch method = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $method = null; - /** - * Optional. Specifies a collection of headers to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch headers = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $headers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\MethodMatch $method - * Optional. A gRPC method to match against. If this field is empty or - * omitted, will match all methods. - * @type array<\Google\Cloud\NetworkServices\V1\GrpcRoute\HeaderMatch>|\Google\Protobuf\Internal\RepeatedField $headers - * Optional. Specifies a collection of headers to match. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A gRPC method to match against. If this field is empty or - * omitted, will match all methods. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.MethodMatch method = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\MethodMatch|null - */ - public function getMethod() - { - return $this->method; - } - - public function hasMethod() - { - return isset($this->method); - } - - public function clearMethod() - { - unset($this->method); - } - - /** - * Optional. A gRPC method to match against. If this field is empty or - * omitted, will match all methods. - * - * Generated from protobuf field optional .google.cloud.networkservices.v1.GrpcRoute.MethodMatch method = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\MethodMatch $var - * @return $this - */ - public function setMethod($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\MethodMatch::class); - $this->method = $var; - - return $this; - } - - /** - * Optional. Specifies a collection of headers to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch headers = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHeaders() - { - return $this->headers; - } - - /** - * Optional. Specifies a collection of headers to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.HeaderMatch headers = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\NetworkServices\V1\GrpcRoute\HeaderMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\GrpcRoute\HeaderMatch::class); - $this->headers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteMatch::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_RouteMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteRule.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteRule.php deleted file mode 100644 index c1eb735a0ee0..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/GrpcRoute/RouteRule.php +++ /dev/null @@ -1,130 +0,0 @@ -google.cloud.networkservices.v1.GrpcRoute.RouteRule - */ -class RouteRule extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Matches define conditions used for matching the rule against - * incoming gRPC requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. If no matches field is - * specified, this rule will unconditionally match traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $matches; - /** - * Required. A detailed rule defining how to route traffic. This field is - * required. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $action = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\GrpcRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $matches - * Optional. Matches define conditions used for matching the rule against - * incoming gRPC requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. If no matches field is - * specified, this rule will unconditionally match traffic. - * @type \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteAction $action - * Required. A detailed rule defining how to route traffic. This field is - * required. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Matches define conditions used for matching the rule against - * incoming gRPC requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. If no matches field is - * specified, this rule will unconditionally match traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMatches() - { - return $this->matches; - } - - /** - * Optional. Matches define conditions used for matching the rule against - * incoming gRPC requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. If no matches field is - * specified, this rule will unconditionally match traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\NetworkServices\V1\GrpcRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMatches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteMatch::class); - $this->matches = $arr; - - return $this; - } - - /** - * Required. A detailed rule defining how to route traffic. This field is - * required. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteAction|null - */ - public function getAction() - { - return $this->action; - } - - public function hasAction() - { - return isset($this->action); - } - - public function clearAction() - { - unset($this->action); - } - - /** - * Required. A detailed rule defining how to route traffic. This field is - * required. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteAction $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute\RouteAction::class); - $this->action = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteRule::class, \Google\Cloud\NetworkServices\V1\GrpcRoute_RouteRule::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute.php deleted file mode 100644 index 7663ee89f61e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute.php +++ /dev/null @@ -1,518 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute - */ -class HttpRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the HttpRoute resource. It matches pattern - * `projects/*/locations/global/httpRoutes/http_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Required. Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - * - * Generated from protobuf field repeated string hostnames = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $hostnames; - /** - * Optional. Meshes defines a list of meshes this HttpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $meshes; - /** - * Optional. Gateways defines a list of gateways this HttpRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $gateways; - /** - * Optional. Set of label tags associated with the HttpRoute resource. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. Rules that define how traffic is routed and handled. - * Rules will be matched sequentially based on the RouteMatch specified for - * the rule. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteRule rules = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - private $rules; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the HttpRoute resource. It matches pattern - * `projects/*/locations/global/httpRoutes/http_route_name>`. - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type array|\Google\Protobuf\Internal\RepeatedField $hostnames - * Required. Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - * @type array|\Google\Protobuf\Internal\RepeatedField $meshes - * Optional. Meshes defines a list of meshes this HttpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * @type array|\Google\Protobuf\Internal\RepeatedField $gateways - * Optional. Gateways defines a list of gateways this HttpRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the HttpRoute resource. - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $rules - * Required. Rules that define how traffic is routed and handled. - * Rules will be matched sequentially based on the RouteMatch specified for - * the rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the HttpRoute resource. It matches pattern - * `projects/*/locations/global/httpRoutes/http_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the HttpRoute resource. It matches pattern - * `projects/*/locations/global/httpRoutes/http_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.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 timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Required. Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - * - * Generated from protobuf field repeated string hostnames = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHostnames() - { - return $this->hostnames; - } - - /** - * Required. Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - * - * Generated from protobuf field repeated string hostnames = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHostnames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->hostnames = $arr; - - return $this; - } - - /** - * Optional. Meshes defines a list of meshes this HttpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMeshes() - { - return $this->meshes; - } - - /** - * Optional. Meshes defines a list of meshes this HttpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMeshes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->meshes = $arr; - - return $this; - } - - /** - * Optional. Gateways defines a list of gateways this HttpRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGateways() - { - return $this->gateways; - } - - /** - * Optional. Gateways defines a list of gateways this HttpRoute is attached - * to, as one of the routing rules to route the requests served by the - * gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->gateways = $arr; - - return $this; - } - - /** - * Optional. Set of label tags associated with the HttpRoute resource. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the HttpRoute resource. - * - * 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; - } - - /** - * Required. Rules that define how traffic is routed and handled. - * Rules will be matched sequentially based on the RouteMatch specified for - * the rule. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteRule rules = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRules() - { - return $this->rules; - } - - /** - * Required. Rules that define how traffic is routed and handled. - * Rules will be matched sequentially based on the RouteMatch specified for - * the rule. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteRule rules = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute\RouteRule::class); - $this->rules = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/CorsPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/CorsPolicy.php deleted file mode 100644 index 5d4f95014991..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/CorsPolicy.php +++ /dev/null @@ -1,344 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.CorsPolicy - */ -class CorsPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies the list of origins that will be allowed to do CORS requests. - * An origin is allowed if it matches either an item in allow_origins or - * an item in allow_origin_regexes. - * - * Generated from protobuf field repeated string allow_origins = 1; - */ - private $allow_origins; - /** - * Specifies the regular expression patterns that match allowed origins. For - * regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax. - * - * Generated from protobuf field repeated string allow_origin_regexes = 2; - */ - private $allow_origin_regexes; - /** - * Specifies the content for Access-Control-Allow-Methods header. - * - * Generated from protobuf field repeated string allow_methods = 3; - */ - private $allow_methods; - /** - * Specifies the content for Access-Control-Allow-Headers header. - * - * Generated from protobuf field repeated string allow_headers = 4; - */ - private $allow_headers; - /** - * Specifies the content for Access-Control-Expose-Headers header. - * - * Generated from protobuf field repeated string expose_headers = 5; - */ - private $expose_headers; - /** - * Specifies how long result of a preflight request can be cached in - * seconds. This translates to the Access-Control-Max-Age header. - * - * Generated from protobuf field string max_age = 6; - */ - protected $max_age = ''; - /** - * In response to a preflight request, setting this to true indicates that - * the actual request can include user credentials. This translates to the - * Access-Control-Allow-Credentials header. - * Default value is false. - * - * Generated from protobuf field bool allow_credentials = 7; - */ - protected $allow_credentials = false; - /** - * If true, the CORS policy is disabled. The default value is false, which - * indicates that the CORS policy is in effect. - * - * Generated from protobuf field bool disabled = 8; - */ - protected $disabled = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $allow_origins - * Specifies the list of origins that will be allowed to do CORS requests. - * An origin is allowed if it matches either an item in allow_origins or - * an item in allow_origin_regexes. - * @type array|\Google\Protobuf\Internal\RepeatedField $allow_origin_regexes - * Specifies the regular expression patterns that match allowed origins. For - * regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax. - * @type array|\Google\Protobuf\Internal\RepeatedField $allow_methods - * Specifies the content for Access-Control-Allow-Methods header. - * @type array|\Google\Protobuf\Internal\RepeatedField $allow_headers - * Specifies the content for Access-Control-Allow-Headers header. - * @type array|\Google\Protobuf\Internal\RepeatedField $expose_headers - * Specifies the content for Access-Control-Expose-Headers header. - * @type string $max_age - * Specifies how long result of a preflight request can be cached in - * seconds. This translates to the Access-Control-Max-Age header. - * @type bool $allow_credentials - * In response to a preflight request, setting this to true indicates that - * the actual request can include user credentials. This translates to the - * Access-Control-Allow-Credentials header. - * Default value is false. - * @type bool $disabled - * If true, the CORS policy is disabled. The default value is false, which - * indicates that the CORS policy is in effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Specifies the list of origins that will be allowed to do CORS requests. - * An origin is allowed if it matches either an item in allow_origins or - * an item in allow_origin_regexes. - * - * Generated from protobuf field repeated string allow_origins = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowOrigins() - { - return $this->allow_origins; - } - - /** - * Specifies the list of origins that will be allowed to do CORS requests. - * An origin is allowed if it matches either an item in allow_origins or - * an item in allow_origin_regexes. - * - * Generated from protobuf field repeated string allow_origins = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowOrigins($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allow_origins = $arr; - - return $this; - } - - /** - * Specifies the regular expression patterns that match allowed origins. For - * regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax. - * - * Generated from protobuf field repeated string allow_origin_regexes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowOriginRegexes() - { - return $this->allow_origin_regexes; - } - - /** - * Specifies the regular expression patterns that match allowed origins. For - * regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax. - * - * Generated from protobuf field repeated string allow_origin_regexes = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowOriginRegexes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allow_origin_regexes = $arr; - - return $this; - } - - /** - * Specifies the content for Access-Control-Allow-Methods header. - * - * Generated from protobuf field repeated string allow_methods = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowMethods() - { - return $this->allow_methods; - } - - /** - * Specifies the content for Access-Control-Allow-Methods header. - * - * Generated from protobuf field repeated string allow_methods = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowMethods($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allow_methods = $arr; - - return $this; - } - - /** - * Specifies the content for Access-Control-Allow-Headers header. - * - * Generated from protobuf field repeated string allow_headers = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowHeaders() - { - return $this->allow_headers; - } - - /** - * Specifies the content for Access-Control-Allow-Headers header. - * - * Generated from protobuf field repeated string allow_headers = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allow_headers = $arr; - - return $this; - } - - /** - * Specifies the content for Access-Control-Expose-Headers header. - * - * Generated from protobuf field repeated string expose_headers = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExposeHeaders() - { - return $this->expose_headers; - } - - /** - * Specifies the content for Access-Control-Expose-Headers header. - * - * Generated from protobuf field repeated string expose_headers = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExposeHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->expose_headers = $arr; - - return $this; - } - - /** - * Specifies how long result of a preflight request can be cached in - * seconds. This translates to the Access-Control-Max-Age header. - * - * Generated from protobuf field string max_age = 6; - * @return string - */ - public function getMaxAge() - { - return $this->max_age; - } - - /** - * Specifies how long result of a preflight request can be cached in - * seconds. This translates to the Access-Control-Max-Age header. - * - * Generated from protobuf field string max_age = 6; - * @param string $var - * @return $this - */ - public function setMaxAge($var) - { - GPBUtil::checkString($var, True); - $this->max_age = $var; - - return $this; - } - - /** - * In response to a preflight request, setting this to true indicates that - * the actual request can include user credentials. This translates to the - * Access-Control-Allow-Credentials header. - * Default value is false. - * - * Generated from protobuf field bool allow_credentials = 7; - * @return bool - */ - public function getAllowCredentials() - { - return $this->allow_credentials; - } - - /** - * In response to a preflight request, setting this to true indicates that - * the actual request can include user credentials. This translates to the - * Access-Control-Allow-Credentials header. - * Default value is false. - * - * Generated from protobuf field bool allow_credentials = 7; - * @param bool $var - * @return $this - */ - public function setAllowCredentials($var) - { - GPBUtil::checkBool($var); - $this->allow_credentials = $var; - - return $this; - } - - /** - * If true, the CORS policy is disabled. The default value is false, which - * indicates that the CORS policy is in effect. - * - * Generated from protobuf field bool disabled = 8; - * @return bool - */ - public function getDisabled() - { - return $this->disabled; - } - - /** - * If true, the CORS policy is disabled. The default value is false, which - * indicates that the CORS policy is in effect. - * - * Generated from protobuf field bool disabled = 8; - * @param bool $var - * @return $this - */ - public function setDisabled($var) - { - GPBUtil::checkBool($var); - $this->disabled = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CorsPolicy::class, \Google\Cloud\NetworkServices\V1\HttpRoute_CorsPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Destination.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Destination.php deleted file mode 100644 index 95357636b4b1..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Destination.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.Destination - */ -class Destination extends \Google\Protobuf\Internal\Message -{ - /** - * The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.resource_reference) = { - */ - protected $service_name = ''; - /** - * Specifies the proportion of requests forwarded to the backend referenced - * by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2; - */ - protected $weight = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * The URL of a BackendService to route traffic to. - * @type int $weight - * Specifies the proportion of requests forwarded to the backend referenced - * by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Specifies the proportion of requests forwarded to the backend referenced - * by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2; - * @return int - */ - public function getWeight() - { - return $this->weight; - } - - /** - * Specifies the proportion of requests forwarded to the backend referenced - * by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2; - * @param int $var - * @return $this - */ - public function setWeight($var) - { - GPBUtil::checkInt32($var); - $this->weight = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Destination::class, \Google\Cloud\NetworkServices\V1\HttpRoute_Destination::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy.php deleted file mode 100644 index 359d7b636738..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy.php +++ /dev/null @@ -1,129 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy - */ -class FaultInjectionPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Delay delay = 1; - */ - protected $delay = null; - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Abort abort = 2; - */ - protected $abort = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Delay $delay - * The specification for injecting delay to client requests. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Abort $abort - * The specification for aborting to client requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Delay delay = 1; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Delay|null - */ - public function getDelay() - { - return $this->delay; - } - - public function hasDelay() - { - return isset($this->delay); - } - - public function clearDelay() - { - unset($this->delay); - } - - /** - * The specification for injecting delay to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Delay delay = 1; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Delay $var - * @return $this - */ - public function setDelay($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Delay::class); - $this->delay = $var; - - return $this; - } - - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Abort abort = 2; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Abort|null - */ - public function getAbort() - { - return $this->abort; - } - - public function hasAbort() - { - return isset($this->abort); - } - - public function clearAbort() - { - unset($this->abort); - } - - /** - * The specification for aborting to client requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Abort abort = 2; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Abort $var - * @return $this - */ - public function setAbort($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy\Abort::class); - $this->abort = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FaultInjectionPolicy::class, \Google\Cloud\NetworkServices\V1\HttpRoute_FaultInjectionPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Abort.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Abort.php deleted file mode 100644 index f190f0610d77..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Abort.php +++ /dev/null @@ -1,113 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Abort - */ -class Abort extends \Google\Protobuf\Internal\Message -{ - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field int32 http_status = 1; - */ - protected $http_status = 0; - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - */ - protected $percentage = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $http_status - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * @type int $percentage - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field int32 http_status = 1; - * @return int - */ - public function getHttpStatus() - { - return $this->http_status; - } - - /** - * The HTTP status code used to abort the request. - * The value must be between 200 and 599 inclusive. - * - * Generated from protobuf field int32 http_status = 1; - * @param int $var - * @return $this - */ - public function setHttpStatus($var) - { - GPBUtil::checkInt32($var); - $this->http_status = $var; - - return $this; - } - - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - * @return int - */ - public function getPercentage() - { - return $this->percentage; - } - - /** - * The percentage of traffic which will be aborted. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - * @param int $var - * @return $this - */ - public function setPercentage($var) - { - GPBUtil::checkInt32($var); - $this->percentage = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Abort::class, \Google\Cloud\NetworkServices\V1\HttpRoute_FaultInjectionPolicy_Abort::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Delay.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Delay.php deleted file mode 100644 index 3fb9852742e7..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/FaultInjectionPolicy/Delay.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy.Delay - */ -class Delay extends \Google\Protobuf\Internal\Message -{ - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field .google.protobuf.Duration fixed_delay = 1; - */ - protected $fixed_delay = null; - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - */ - protected $percentage = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Duration $fixed_delay - * Specify a fixed delay before forwarding the request. - * @type int $percentage - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field .google.protobuf.Duration fixed_delay = 1; - * @return \Google\Protobuf\Duration|null - */ - public function getFixedDelay() - { - return $this->fixed_delay; - } - - public function hasFixedDelay() - { - return isset($this->fixed_delay); - } - - public function clearFixedDelay() - { - unset($this->fixed_delay); - } - - /** - * Specify a fixed delay before forwarding the request. - * - * Generated from protobuf field .google.protobuf.Duration fixed_delay = 1; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setFixedDelay($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->fixed_delay = $var; - - return $this; - } - - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - * @return int - */ - public function getPercentage() - { - return $this->percentage; - } - - /** - * The percentage of traffic on which delay will be injected. - * The value must be between [0, 100] - * - * Generated from protobuf field int32 percentage = 2; - * @param int $var - * @return $this - */ - public function setPercentage($var) - { - GPBUtil::checkInt32($var); - $this->percentage = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Delay::class, \Google\Cloud\NetworkServices\V1\HttpRoute_FaultInjectionPolicy_Delay::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch.php deleted file mode 100644 index 9bb4ffab022a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch.php +++ /dev/null @@ -1,330 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.HeaderMatch - */ -class HeaderMatch extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the HTTP header to match against. - * - * Generated from protobuf field string header = 1; - */ - protected $header = ''; - /** - * If specified, the match result will be inverted before checking. Default - * value is set to false. - * - * Generated from protobuf field bool invert_match = 8; - */ - protected $invert_match = false; - protected $MatchType; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $exact_match - * The value of the header should match exactly the content of - * exact_match. - * @type string $regex_match - * The value of the header must match the regular expression specified in - * regex_match. For regular expression grammar, please see: - * https://github.com/google/re2/wiki/Syntax - * @type string $prefix_match - * The value of the header must start with the contents of prefix_match. - * @type bool $present_match - * A header with header_name must exist. The match takes place whether or - * not the header has a value. - * @type string $suffix_match - * The value of the header must end with the contents of suffix_match. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch\IntegerRange $range_match - * If specified, the rule will match if the request header value is within - * the range. - * @type string $header - * The name of the HTTP header to match against. - * @type bool $invert_match - * If specified, the match result will be inverted before checking. Default - * value is set to false. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The value of the header should match exactly the content of - * exact_match. - * - * Generated from protobuf field string exact_match = 2; - * @return string - */ - public function getExactMatch() - { - return $this->readOneof(2); - } - - public function hasExactMatch() - { - return $this->hasOneof(2); - } - - /** - * The value of the header should match exactly the content of - * exact_match. - * - * Generated from protobuf field string exact_match = 2; - * @param string $var - * @return $this - */ - public function setExactMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The value of the header must match the regular expression specified in - * regex_match. For regular expression grammar, please see: - * https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string regex_match = 3; - * @return string - */ - public function getRegexMatch() - { - return $this->readOneof(3); - } - - public function hasRegexMatch() - { - return $this->hasOneof(3); - } - - /** - * The value of the header must match the regular expression specified in - * regex_match. For regular expression grammar, please see: - * https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string regex_match = 3; - * @param string $var - * @return $this - */ - public function setRegexMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * The value of the header must start with the contents of prefix_match. - * - * Generated from protobuf field string prefix_match = 4; - * @return string - */ - public function getPrefixMatch() - { - return $this->readOneof(4); - } - - public function hasPrefixMatch() - { - return $this->hasOneof(4); - } - - /** - * The value of the header must start with the contents of prefix_match. - * - * Generated from protobuf field string prefix_match = 4; - * @param string $var - * @return $this - */ - public function setPrefixMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A header with header_name must exist. The match takes place whether or - * not the header has a value. - * - * Generated from protobuf field bool present_match = 5; - * @return bool - */ - public function getPresentMatch() - { - return $this->readOneof(5); - } - - public function hasPresentMatch() - { - return $this->hasOneof(5); - } - - /** - * A header with header_name must exist. The match takes place whether or - * not the header has a value. - * - * Generated from protobuf field bool present_match = 5; - * @param bool $var - * @return $this - */ - public function setPresentMatch($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * The value of the header must end with the contents of suffix_match. - * - * Generated from protobuf field string suffix_match = 6; - * @return string - */ - public function getSuffixMatch() - { - return $this->readOneof(6); - } - - public function hasSuffixMatch() - { - return $this->hasOneof(6); - } - - /** - * The value of the header must end with the contents of suffix_match. - * - * Generated from protobuf field string suffix_match = 6; - * @param string $var - * @return $this - */ - public function setSuffixMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * If specified, the rule will match if the request header value is within - * the range. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderMatch.IntegerRange range_match = 7; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch\IntegerRange|null - */ - public function getRangeMatch() - { - return $this->readOneof(7); - } - - public function hasRangeMatch() - { - return $this->hasOneof(7); - } - - /** - * If specified, the rule will match if the request header value is within - * the range. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderMatch.IntegerRange range_match = 7; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch\IntegerRange $var - * @return $this - */ - public function setRangeMatch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch\IntegerRange::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * The name of the HTTP header to match against. - * - * Generated from protobuf field string header = 1; - * @return string - */ - public function getHeader() - { - return $this->header; - } - - /** - * The name of the HTTP header to match against. - * - * Generated from protobuf field string header = 1; - * @param string $var - * @return $this - */ - public function setHeader($var) - { - GPBUtil::checkString($var, True); - $this->header = $var; - - return $this; - } - - /** - * If specified, the match result will be inverted before checking. Default - * value is set to false. - * - * Generated from protobuf field bool invert_match = 8; - * @return bool - */ - public function getInvertMatch() - { - return $this->invert_match; - } - - /** - * If specified, the match result will be inverted before checking. Default - * value is set to false. - * - * Generated from protobuf field bool invert_match = 8; - * @param bool $var - * @return $this - */ - public function setInvertMatch($var) - { - GPBUtil::checkBool($var); - $this->invert_match = $var; - - return $this; - } - - /** - * @return string - */ - public function getMatchType() - { - return $this->whichOneof("MatchType"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HeaderMatch::class, \Google\Cloud\NetworkServices\V1\HttpRoute_HeaderMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch/IntegerRange.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch/IntegerRange.php deleted file mode 100644 index 553192944963..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderMatch/IntegerRange.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.HeaderMatch.IntegerRange - */ -class IntegerRange extends \Google\Protobuf\Internal\Message -{ - /** - * Start of the range (inclusive) - * - * Generated from protobuf field int32 start = 1; - */ - protected $start = 0; - /** - * End of the range (exclusive) - * - * Generated from protobuf field int32 end = 2; - */ - protected $end = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $start - * Start of the range (inclusive) - * @type int $end - * End of the range (exclusive) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Start of the range (inclusive) - * - * Generated from protobuf field int32 start = 1; - * @return int - */ - public function getStart() - { - return $this->start; - } - - /** - * Start of the range (inclusive) - * - * Generated from protobuf field int32 start = 1; - * @param int $var - * @return $this - */ - public function setStart($var) - { - GPBUtil::checkInt32($var); - $this->start = $var; - - return $this; - } - - /** - * End of the range (exclusive) - * - * Generated from protobuf field int32 end = 2; - * @return int - */ - public function getEnd() - { - return $this->end; - } - - /** - * End of the range (exclusive) - * - * Generated from protobuf field int32 end = 2; - * @param int $var - * @return $this - */ - public function setEnd($var) - { - GPBUtil::checkInt32($var); - $this->end = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(IntegerRange::class, \Google\Cloud\NetworkServices\V1\HttpRoute_HeaderMatch_IntegerRange::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderModifier.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderModifier.php deleted file mode 100644 index 236b99df598d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/HeaderModifier.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.HeaderModifier - */ -class HeaderModifier extends \Google\Protobuf\Internal\Message -{ - /** - * Completely overwrite/replace the headers with given map where key is the - * name of the header, value is the value of the header. - * - * Generated from protobuf field map set = 1; - */ - private $set; - /** - * Add the headers with given map where key is the name of the header, value - * is the value of the header. - * - * Generated from protobuf field map add = 2; - */ - private $add; - /** - * Remove headers (matching by header names) specified in the list. - * - * Generated from protobuf field repeated string remove = 3; - */ - private $remove; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $set - * Completely overwrite/replace the headers with given map where key is the - * name of the header, value is the value of the header. - * @type array|\Google\Protobuf\Internal\MapField $add - * Add the headers with given map where key is the name of the header, value - * is the value of the header. - * @type array|\Google\Protobuf\Internal\RepeatedField $remove - * Remove headers (matching by header names) specified in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Completely overwrite/replace the headers with given map where key is the - * name of the header, value is the value of the header. - * - * Generated from protobuf field map set = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSet() - { - return $this->set; - } - - /** - * Completely overwrite/replace the headers with given map where key is the - * name of the header, value is the value of the header. - * - * Generated from protobuf field map set = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSet($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->set = $arr; - - return $this; - } - - /** - * Add the headers with given map where key is the name of the header, value - * is the value of the header. - * - * Generated from protobuf field map add = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAdd() - { - return $this->add; - } - - /** - * Add the headers with given map where key is the name of the header, value - * is the value of the header. - * - * Generated from protobuf field map add = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAdd($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->add = $arr; - - return $this; - } - - /** - * Remove headers (matching by header names) specified in the list. - * - * Generated from protobuf field repeated string remove = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRemove() - { - return $this->remove; - } - - /** - * Remove headers (matching by header names) specified in the list. - * - * Generated from protobuf field repeated string remove = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRemove($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->remove = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HeaderModifier::class, \Google\Cloud\NetworkServices\V1\HttpRoute_HeaderModifier::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/QueryParameterMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/QueryParameterMatch.php deleted file mode 100644 index 498cf9ce46be..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/QueryParameterMatch.php +++ /dev/null @@ -1,202 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.QueryParameterMatch - */ -class QueryParameterMatch extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the query parameter to match. - * - * Generated from protobuf field string query_parameter = 1; - */ - protected $query_parameter = ''; - protected $MatchType; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $exact_match - * The value of the query parameter must exactly match the contents of - * exact_match. - * Only one of exact_match, regex_match, or present_match must be set. - * @type string $regex_match - * The value of the query parameter must match the regular expression - * specified by regex_match. For regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax - * Only one of exact_match, regex_match, or present_match must be set. - * @type bool $present_match - * Specifies that the QueryParameterMatcher matches if request contains - * query parameter, irrespective of whether the parameter has a value or - * not. - * Only one of exact_match, regex_match, or present_match must be set. - * @type string $query_parameter - * The name of the query parameter to match. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The value of the query parameter must exactly match the contents of - * exact_match. - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field string exact_match = 2; - * @return string - */ - public function getExactMatch() - { - return $this->readOneof(2); - } - - public function hasExactMatch() - { - return $this->hasOneof(2); - } - - /** - * The value of the query parameter must exactly match the contents of - * exact_match. - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field string exact_match = 2; - * @param string $var - * @return $this - */ - public function setExactMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The value of the query parameter must match the regular expression - * specified by regex_match. For regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field string regex_match = 3; - * @return string - */ - public function getRegexMatch() - { - return $this->readOneof(3); - } - - public function hasRegexMatch() - { - return $this->hasOneof(3); - } - - /** - * The value of the query parameter must match the regular expression - * specified by regex_match. For regular expression grammar, please see - * https://github.com/google/re2/wiki/Syntax - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field string regex_match = 3; - * @param string $var - * @return $this - */ - public function setRegexMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Specifies that the QueryParameterMatcher matches if request contains - * query parameter, irrespective of whether the parameter has a value or - * not. - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field bool present_match = 4; - * @return bool - */ - public function getPresentMatch() - { - return $this->readOneof(4); - } - - public function hasPresentMatch() - { - return $this->hasOneof(4); - } - - /** - * Specifies that the QueryParameterMatcher matches if request contains - * query parameter, irrespective of whether the parameter has a value or - * not. - * Only one of exact_match, regex_match, or present_match must be set. - * - * Generated from protobuf field bool present_match = 4; - * @param bool $var - * @return $this - */ - public function setPresentMatch($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * The name of the query parameter to match. - * - * Generated from protobuf field string query_parameter = 1; - * @return string - */ - public function getQueryParameter() - { - return $this->query_parameter; - } - - /** - * The name of the query parameter to match. - * - * Generated from protobuf field string query_parameter = 1; - * @param string $var - * @return $this - */ - public function setQueryParameter($var) - { - GPBUtil::checkString($var, True); - $this->query_parameter = $var; - - return $this; - } - - /** - * @return string - */ - public function getMatchType() - { - return $this->whichOneof("MatchType"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(QueryParameterMatch::class, \Google\Cloud\NetworkServices\V1\HttpRoute_QueryParameterMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect.php deleted file mode 100644 index 044a694184e1..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect.php +++ /dev/null @@ -1,330 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.Redirect - */ -class Redirect extends \Google\Protobuf\Internal\Message -{ - /** - * The host that will be used in the redirect response instead of the one - * that was supplied in the request. - * - * Generated from protobuf field string host_redirect = 1; - */ - protected $host_redirect = ''; - /** - * The path that will be used in the redirect response instead of the one - * that was supplied in the request. - * path_redirect can not be supplied together with prefix_redirect. Supply - * one alone or neither. If neither is supplied, the path of the original - * request will be used for the redirect. - * - * Generated from protobuf field string path_redirect = 2; - */ - protected $path_redirect = ''; - /** - * Indicates that during redirection, the matched prefix (or path) should be - * swapped with this value. This option allows URLs be dynamically created - * based on the request. - * - * Generated from protobuf field string prefix_rewrite = 3; - */ - protected $prefix_rewrite = ''; - /** - * The HTTP Status code to use for the redirect. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect.ResponseCode response_code = 4; - */ - protected $response_code = 0; - /** - * If set to true, the URL scheme in the redirected request is set to https. - * If set to false, the URL scheme of the redirected request will remain the - * same as that of the request. - * The default is set to false. - * - * Generated from protobuf field bool https_redirect = 5; - */ - protected $https_redirect = false; - /** - * if set to true, any accompanying query portion of the original URL is - * removed prior to redirecting the request. If set to false, the query - * portion of the original URL is retained. - * The default is set to false. - * - * Generated from protobuf field bool strip_query = 6; - */ - protected $strip_query = false; - /** - * The port that will be used in the redirected request instead of the one - * that was supplied in the request. - * - * Generated from protobuf field int32 port_redirect = 7; - */ - protected $port_redirect = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $host_redirect - * The host that will be used in the redirect response instead of the one - * that was supplied in the request. - * @type string $path_redirect - * The path that will be used in the redirect response instead of the one - * that was supplied in the request. - * path_redirect can not be supplied together with prefix_redirect. Supply - * one alone or neither. If neither is supplied, the path of the original - * request will be used for the redirect. - * @type string $prefix_rewrite - * Indicates that during redirection, the matched prefix (or path) should be - * swapped with this value. This option allows URLs be dynamically created - * based on the request. - * @type int $response_code - * The HTTP Status code to use for the redirect. - * @type bool $https_redirect - * If set to true, the URL scheme in the redirected request is set to https. - * If set to false, the URL scheme of the redirected request will remain the - * same as that of the request. - * The default is set to false. - * @type bool $strip_query - * if set to true, any accompanying query portion of the original URL is - * removed prior to redirecting the request. If set to false, the query - * portion of the original URL is retained. - * The default is set to false. - * @type int $port_redirect - * The port that will be used in the redirected request instead of the one - * that was supplied in the request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The host that will be used in the redirect response instead of the one - * that was supplied in the request. - * - * Generated from protobuf field string host_redirect = 1; - * @return string - */ - public function getHostRedirect() - { - return $this->host_redirect; - } - - /** - * The host that will be used in the redirect response instead of the one - * that was supplied in the request. - * - * Generated from protobuf field string host_redirect = 1; - * @param string $var - * @return $this - */ - public function setHostRedirect($var) - { - GPBUtil::checkString($var, True); - $this->host_redirect = $var; - - return $this; - } - - /** - * The path that will be used in the redirect response instead of the one - * that was supplied in the request. - * path_redirect can not be supplied together with prefix_redirect. Supply - * one alone or neither. If neither is supplied, the path of the original - * request will be used for the redirect. - * - * Generated from protobuf field string path_redirect = 2; - * @return string - */ - public function getPathRedirect() - { - return $this->path_redirect; - } - - /** - * The path that will be used in the redirect response instead of the one - * that was supplied in the request. - * path_redirect can not be supplied together with prefix_redirect. Supply - * one alone or neither. If neither is supplied, the path of the original - * request will be used for the redirect. - * - * Generated from protobuf field string path_redirect = 2; - * @param string $var - * @return $this - */ - public function setPathRedirect($var) - { - GPBUtil::checkString($var, True); - $this->path_redirect = $var; - - return $this; - } - - /** - * Indicates that during redirection, the matched prefix (or path) should be - * swapped with this value. This option allows URLs be dynamically created - * based on the request. - * - * Generated from protobuf field string prefix_rewrite = 3; - * @return string - */ - public function getPrefixRewrite() - { - return $this->prefix_rewrite; - } - - /** - * Indicates that during redirection, the matched prefix (or path) should be - * swapped with this value. This option allows URLs be dynamically created - * based on the request. - * - * Generated from protobuf field string prefix_rewrite = 3; - * @param string $var - * @return $this - */ - public function setPrefixRewrite($var) - { - GPBUtil::checkString($var, True); - $this->prefix_rewrite = $var; - - return $this; - } - - /** - * The HTTP Status code to use for the redirect. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect.ResponseCode response_code = 4; - * @return int - */ - public function getResponseCode() - { - return $this->response_code; - } - - /** - * The HTTP Status code to use for the redirect. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect.ResponseCode response_code = 4; - * @param int $var - * @return $this - */ - public function setResponseCode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\HttpRoute\Redirect\ResponseCode::class); - $this->response_code = $var; - - return $this; - } - - /** - * If set to true, the URL scheme in the redirected request is set to https. - * If set to false, the URL scheme of the redirected request will remain the - * same as that of the request. - * The default is set to false. - * - * Generated from protobuf field bool https_redirect = 5; - * @return bool - */ - public function getHttpsRedirect() - { - return $this->https_redirect; - } - - /** - * If set to true, the URL scheme in the redirected request is set to https. - * If set to false, the URL scheme of the redirected request will remain the - * same as that of the request. - * The default is set to false. - * - * Generated from protobuf field bool https_redirect = 5; - * @param bool $var - * @return $this - */ - public function setHttpsRedirect($var) - { - GPBUtil::checkBool($var); - $this->https_redirect = $var; - - return $this; - } - - /** - * if set to true, any accompanying query portion of the original URL is - * removed prior to redirecting the request. If set to false, the query - * portion of the original URL is retained. - * The default is set to false. - * - * Generated from protobuf field bool strip_query = 6; - * @return bool - */ - public function getStripQuery() - { - return $this->strip_query; - } - - /** - * if set to true, any accompanying query portion of the original URL is - * removed prior to redirecting the request. If set to false, the query - * portion of the original URL is retained. - * The default is set to false. - * - * Generated from protobuf field bool strip_query = 6; - * @param bool $var - * @return $this - */ - public function setStripQuery($var) - { - GPBUtil::checkBool($var); - $this->strip_query = $var; - - return $this; - } - - /** - * The port that will be used in the redirected request instead of the one - * that was supplied in the request. - * - * Generated from protobuf field int32 port_redirect = 7; - * @return int - */ - public function getPortRedirect() - { - return $this->port_redirect; - } - - /** - * The port that will be used in the redirected request instead of the one - * that was supplied in the request. - * - * Generated from protobuf field int32 port_redirect = 7; - * @param int $var - * @return $this - */ - public function setPortRedirect($var) - { - GPBUtil::checkInt32($var); - $this->port_redirect = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Redirect::class, \Google\Cloud\NetworkServices\V1\HttpRoute_Redirect::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect/ResponseCode.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect/ResponseCode.php deleted file mode 100644 index 15f341d6c08f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/Redirect/ResponseCode.php +++ /dev/null @@ -1,85 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.Redirect.ResponseCode - */ -class ResponseCode -{ - /** - * Default value - * - * Generated from protobuf enum RESPONSE_CODE_UNSPECIFIED = 0; - */ - const RESPONSE_CODE_UNSPECIFIED = 0; - /** - * Corresponds to 301. - * - * Generated from protobuf enum MOVED_PERMANENTLY_DEFAULT = 1; - */ - const MOVED_PERMANENTLY_DEFAULT = 1; - /** - * Corresponds to 302. - * - * Generated from protobuf enum FOUND = 2; - */ - const FOUND = 2; - /** - * Corresponds to 303. - * - * Generated from protobuf enum SEE_OTHER = 3; - */ - const SEE_OTHER = 3; - /** - * Corresponds to 307. In this case, the request method will be retained. - * - * Generated from protobuf enum TEMPORARY_REDIRECT = 4; - */ - const TEMPORARY_REDIRECT = 4; - /** - * Corresponds to 308. In this case, the request method will be retained. - * - * Generated from protobuf enum PERMANENT_REDIRECT = 5; - */ - const PERMANENT_REDIRECT = 5; - - private static $valueToName = [ - self::RESPONSE_CODE_UNSPECIFIED => 'RESPONSE_CODE_UNSPECIFIED', - self::MOVED_PERMANENTLY_DEFAULT => 'MOVED_PERMANENTLY_DEFAULT', - self::FOUND => 'FOUND', - self::SEE_OTHER => 'SEE_OTHER', - self::TEMPORARY_REDIRECT => 'TEMPORARY_REDIRECT', - self::PERMANENT_REDIRECT => 'PERMANENT_REDIRECT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ResponseCode::class, \Google\Cloud\NetworkServices\V1\HttpRoute_Redirect_ResponseCode::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RequestMirrorPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RequestMirrorPolicy.php deleted file mode 100644 index 706091e03e04..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RequestMirrorPolicy.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.RequestMirrorPolicy - */ -class RequestMirrorPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The destination the requests will be mirrored to. The weight of the - * destination will be ignored. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Destination destination = 1; - */ - protected $destination = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\Destination $destination - * The destination the requests will be mirrored to. The weight of the - * destination will be ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The destination the requests will be mirrored to. The weight of the - * destination will be ignored. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Destination destination = 1; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\Destination|null - */ - public function getDestination() - { - return $this->destination; - } - - public function hasDestination() - { - return isset($this->destination); - } - - public function clearDestination() - { - unset($this->destination); - } - - /** - * The destination the requests will be mirrored to. The weight of the - * destination will be ignored. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Destination destination = 1; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\Destination $var - * @return $this - */ - public function setDestination($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\Destination::class); - $this->destination = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RequestMirrorPolicy::class, \Google\Cloud\NetworkServices\V1\HttpRoute_RequestMirrorPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RetryPolicy.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RetryPolicy.php deleted file mode 100644 index eafe92344ce6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RetryPolicy.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.RetryPolicy - */ -class RetryPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies one or more conditions when this retry policy applies. Valid - * values are: - * 5xx: Proxy will attempt a retry if the destination service responds - * with any 5xx response code, of if the destination service does not - * respond at all, example: disconnect, reset, read timeout, connection - * failure and refused streams. - * gateway-error: Similar to 5xx, but only applies to response codes 502, - * 503, 504. - * reset: Proxy will attempt a retry if the destination service does not - * respond at all (disconnect/reset/read timeout) - * connect-failure: Proxy will retry on failures connecting to destination - * for example due to connection timeouts. - * retriable-4xx: Proxy will retry fro retriable 4xx response codes. - * Currently the only retriable error supported is 409. - * refused-stream: Proxy will retry if the destination resets the stream - * with a REFUSED_STREAM error code. This reset type indicates that it - * is safe to retry. - * - * Generated from protobuf field repeated string retry_conditions = 1; - */ - private $retry_conditions; - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field int32 num_retries = 2; - */ - protected $num_retries = 0; - /** - * Specifies a non-zero timeout per retry attempt. - * - * Generated from protobuf field .google.protobuf.Duration per_try_timeout = 3; - */ - protected $per_try_timeout = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $retry_conditions - * Specifies one or more conditions when this retry policy applies. Valid - * values are: - * 5xx: Proxy will attempt a retry if the destination service responds - * with any 5xx response code, of if the destination service does not - * respond at all, example: disconnect, reset, read timeout, connection - * failure and refused streams. - * gateway-error: Similar to 5xx, but only applies to response codes 502, - * 503, 504. - * reset: Proxy will attempt a retry if the destination service does not - * respond at all (disconnect/reset/read timeout) - * connect-failure: Proxy will retry on failures connecting to destination - * for example due to connection timeouts. - * retriable-4xx: Proxy will retry fro retriable 4xx response codes. - * Currently the only retriable error supported is 409. - * refused-stream: Proxy will retry if the destination resets the stream - * with a REFUSED_STREAM error code. This reset type indicates that it - * is safe to retry. - * @type int $num_retries - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * @type \Google\Protobuf\Duration $per_try_timeout - * Specifies a non-zero timeout per retry attempt. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Specifies one or more conditions when this retry policy applies. Valid - * values are: - * 5xx: Proxy will attempt a retry if the destination service responds - * with any 5xx response code, of if the destination service does not - * respond at all, example: disconnect, reset, read timeout, connection - * failure and refused streams. - * gateway-error: Similar to 5xx, but only applies to response codes 502, - * 503, 504. - * reset: Proxy will attempt a retry if the destination service does not - * respond at all (disconnect/reset/read timeout) - * connect-failure: Proxy will retry on failures connecting to destination - * for example due to connection timeouts. - * retriable-4xx: Proxy will retry fro retriable 4xx response codes. - * Currently the only retriable error supported is 409. - * refused-stream: Proxy will retry if the destination resets the stream - * with a REFUSED_STREAM error code. This reset type indicates that it - * is safe to retry. - * - * Generated from protobuf field repeated string retry_conditions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRetryConditions() - { - return $this->retry_conditions; - } - - /** - * Specifies one or more conditions when this retry policy applies. Valid - * values are: - * 5xx: Proxy will attempt a retry if the destination service responds - * with any 5xx response code, of if the destination service does not - * respond at all, example: disconnect, reset, read timeout, connection - * failure and refused streams. - * gateway-error: Similar to 5xx, but only applies to response codes 502, - * 503, 504. - * reset: Proxy will attempt a retry if the destination service does not - * respond at all (disconnect/reset/read timeout) - * connect-failure: Proxy will retry on failures connecting to destination - * for example due to connection timeouts. - * retriable-4xx: Proxy will retry fro retriable 4xx response codes. - * Currently the only retriable error supported is 409. - * refused-stream: Proxy will retry if the destination resets the stream - * with a REFUSED_STREAM error code. This reset type indicates that it - * is safe to retry. - * - * Generated from protobuf field repeated string retry_conditions = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRetryConditions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->retry_conditions = $arr; - - return $this; - } - - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field int32 num_retries = 2; - * @return int - */ - public function getNumRetries() - { - return $this->num_retries; - } - - /** - * Specifies the allowed number of retries. This number must be > 0. If not - * specified, default to 1. - * - * Generated from protobuf field int32 num_retries = 2; - * @param int $var - * @return $this - */ - public function setNumRetries($var) - { - GPBUtil::checkInt32($var); - $this->num_retries = $var; - - return $this; - } - - /** - * Specifies a non-zero timeout per retry attempt. - * - * Generated from protobuf field .google.protobuf.Duration per_try_timeout = 3; - * @return \Google\Protobuf\Duration|null - */ - public function getPerTryTimeout() - { - return $this->per_try_timeout; - } - - public function hasPerTryTimeout() - { - return isset($this->per_try_timeout); - } - - public function clearPerTryTimeout() - { - unset($this->per_try_timeout); - } - - /** - * Specifies a non-zero timeout per retry attempt. - * - * Generated from protobuf field .google.protobuf.Duration per_try_timeout = 3; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setPerTryTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->per_try_timeout = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RetryPolicy::class, \Google\Cloud\NetworkServices\V1\HttpRoute_RetryPolicy::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteAction.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteAction.php deleted file mode 100644 index 863e7c5acd62..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteAction.php +++ /dev/null @@ -1,546 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.RouteAction - */ -class RouteAction extends \Google\Protobuf\Internal\Message -{ - /** - * The destination to which traffic should be forwarded. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.Destination destinations = 1; - */ - private $destinations; - /** - * If set, the request is directed as configured by this field. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect redirect = 2; - */ - protected $redirect = null; - /** - * The specification for fault injection introduced into traffic to test the - * resiliency of clients to backend service failure. As part of fault - * injection, when clients send requests to a backend service, delays can be - * introduced on a percentage of requests before sending those requests to - * the backend service. Similarly requests from clients can be aborted for a - * percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy fault_injection_policy = 4; - */ - protected $fault_injection_policy = null; - /** - * The specification for modifying the headers of a matching request prior - * to delivery of the request to the destination. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 5; - */ - protected $request_header_modifier = null; - /** - * The specification for modifying the headers of a response prior to - * sending the response back to the client. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 6; - */ - protected $response_header_modifier = null; - /** - * The specification for rewrite URL before forwarding requests to the - * destination. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.URLRewrite url_rewrite = 7; - */ - protected $url_rewrite = null; - /** - * Specifies the timeout for selected route. Timeout is computed from the - * time the request has been fully processed (i.e. end of stream) up until - * the response has been completely processed. Timeout includes all retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - */ - protected $timeout = null; - /** - * Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RetryPolicy retry_policy = 9; - */ - protected $retry_policy = null; - /** - * Specifies the policy on how requests intended for the routes destination - * are shadowed to a separate mirrored destination. Proxy will not wait for - * the shadow destination to respond before returning the response. Prior to - * sending traffic to the shadow service, the host/authority header is - * suffixed with -shadow. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RequestMirrorPolicy request_mirror_policy = 10; - */ - protected $request_mirror_policy = null; - /** - * The specification for allowing client side cross-origin requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.CorsPolicy cors_policy = 11; - */ - protected $cors_policy = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute\Destination>|\Google\Protobuf\Internal\RepeatedField $destinations - * The destination to which traffic should be forwarded. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\Redirect $redirect - * If set, the request is directed as configured by this field. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy $fault_injection_policy - * The specification for fault injection introduced into traffic to test the - * resiliency of clients to backend service failure. As part of fault - * injection, when clients send requests to a backend service, delays can be - * introduced on a percentage of requests before sending those requests to - * the backend service. Similarly requests from clients can be aborted for a - * percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier $request_header_modifier - * The specification for modifying the headers of a matching request prior - * to delivery of the request to the destination. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier $response_header_modifier - * The specification for modifying the headers of a response prior to - * sending the response back to the client. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\URLRewrite $url_rewrite - * The specification for rewrite URL before forwarding requests to the - * destination. - * @type \Google\Protobuf\Duration $timeout - * Specifies the timeout for selected route. Timeout is computed from the - * time the request has been fully processed (i.e. end of stream) up until - * the response has been completely processed. Timeout includes all retries. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\RetryPolicy $retry_policy - * Specifies the retry policy associated with this route. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\RequestMirrorPolicy $request_mirror_policy - * Specifies the policy on how requests intended for the routes destination - * are shadowed to a separate mirrored destination. Proxy will not wait for - * the shadow destination to respond before returning the response. Prior to - * sending traffic to the shadow service, the host/authority header is - * suffixed with -shadow. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\CorsPolicy $cors_policy - * The specification for allowing client side cross-origin requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The destination to which traffic should be forwarded. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.Destination destinations = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDestinations() - { - return $this->destinations; - } - - /** - * The destination to which traffic should be forwarded. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.Destination destinations = 1; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute\Destination>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDestinations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute\Destination::class); - $this->destinations = $arr; - - return $this; - } - - /** - * If set, the request is directed as configured by this field. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect redirect = 2; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\Redirect|null - */ - public function getRedirect() - { - return $this->redirect; - } - - public function hasRedirect() - { - return isset($this->redirect); - } - - public function clearRedirect() - { - unset($this->redirect); - } - - /** - * If set, the request is directed as configured by this field. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.Redirect redirect = 2; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\Redirect $var - * @return $this - */ - public function setRedirect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\Redirect::class); - $this->redirect = $var; - - return $this; - } - - /** - * The specification for fault injection introduced into traffic to test the - * resiliency of clients to backend service failure. As part of fault - * injection, when clients send requests to a backend service, delays can be - * introduced on a percentage of requests before sending those requests to - * the backend service. Similarly requests from clients can be aborted for a - * percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy fault_injection_policy = 4; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy|null - */ - public function getFaultInjectionPolicy() - { - return $this->fault_injection_policy; - } - - public function hasFaultInjectionPolicy() - { - return isset($this->fault_injection_policy); - } - - public function clearFaultInjectionPolicy() - { - unset($this->fault_injection_policy); - } - - /** - * The specification for fault injection introduced into traffic to test the - * resiliency of clients to backend service failure. As part of fault - * injection, when clients send requests to a backend service, delays can be - * introduced on a percentage of requests before sending those requests to - * the backend service. Similarly requests from clients can be aborted for a - * percentage of requests. - * timeout and retry_policy will be ignored by clients that are configured - * with a fault_injection_policy - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.FaultInjectionPolicy fault_injection_policy = 4; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy $var - * @return $this - */ - public function setFaultInjectionPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\FaultInjectionPolicy::class); - $this->fault_injection_policy = $var; - - return $this; - } - - /** - * The specification for modifying the headers of a matching request prior - * to delivery of the request to the destination. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 5; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier|null - */ - public function getRequestHeaderModifier() - { - return $this->request_header_modifier; - } - - public function hasRequestHeaderModifier() - { - return isset($this->request_header_modifier); - } - - public function clearRequestHeaderModifier() - { - unset($this->request_header_modifier); - } - - /** - * The specification for modifying the headers of a matching request prior - * to delivery of the request to the destination. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 5; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier $var - * @return $this - */ - public function setRequestHeaderModifier($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier::class); - $this->request_header_modifier = $var; - - return $this; - } - - /** - * The specification for modifying the headers of a response prior to - * sending the response back to the client. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 6; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier|null - */ - public function getResponseHeaderModifier() - { - return $this->response_header_modifier; - } - - public function hasResponseHeaderModifier() - { - return isset($this->response_header_modifier); - } - - public function clearResponseHeaderModifier() - { - unset($this->response_header_modifier); - } - - /** - * The specification for modifying the headers of a response prior to - * sending the response back to the client. If HeaderModifiers are set - * on both the Destination and the RouteAction, they will be merged. - * Conflicts between the two will not be resolved on the configuration. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 6; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier $var - * @return $this - */ - public function setResponseHeaderModifier($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderModifier::class); - $this->response_header_modifier = $var; - - return $this; - } - - /** - * The specification for rewrite URL before forwarding requests to the - * destination. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.URLRewrite url_rewrite = 7; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\URLRewrite|null - */ - public function getUrlRewrite() - { - return $this->url_rewrite; - } - - public function hasUrlRewrite() - { - return isset($this->url_rewrite); - } - - public function clearUrlRewrite() - { - unset($this->url_rewrite); - } - - /** - * The specification for rewrite URL before forwarding requests to the - * destination. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.URLRewrite url_rewrite = 7; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\URLRewrite $var - * @return $this - */ - public function setUrlRewrite($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\URLRewrite::class); - $this->url_rewrite = $var; - - return $this; - } - - /** - * Specifies the timeout for selected route. Timeout is computed from the - * time the request has been fully processed (i.e. end of stream) up until - * the response has been completely processed. Timeout includes all retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Specifies the timeout for selected route. Timeout is computed from the - * time the request has been fully processed (i.e. end of stream) up until - * the response has been completely processed. Timeout includes all retries. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RetryPolicy retry_policy = 9; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\RetryPolicy|null - */ - public function getRetryPolicy() - { - return $this->retry_policy; - } - - public function hasRetryPolicy() - { - return isset($this->retry_policy); - } - - public function clearRetryPolicy() - { - unset($this->retry_policy); - } - - /** - * Specifies the retry policy associated with this route. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RetryPolicy retry_policy = 9; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\RetryPolicy $var - * @return $this - */ - public function setRetryPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\RetryPolicy::class); - $this->retry_policy = $var; - - return $this; - } - - /** - * Specifies the policy on how requests intended for the routes destination - * are shadowed to a separate mirrored destination. Proxy will not wait for - * the shadow destination to respond before returning the response. Prior to - * sending traffic to the shadow service, the host/authority header is - * suffixed with -shadow. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RequestMirrorPolicy request_mirror_policy = 10; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\RequestMirrorPolicy|null - */ - public function getRequestMirrorPolicy() - { - return $this->request_mirror_policy; - } - - public function hasRequestMirrorPolicy() - { - return isset($this->request_mirror_policy); - } - - public function clearRequestMirrorPolicy() - { - unset($this->request_mirror_policy); - } - - /** - * Specifies the policy on how requests intended for the routes destination - * are shadowed to a separate mirrored destination. Proxy will not wait for - * the shadow destination to respond before returning the response. Prior to - * sending traffic to the shadow service, the host/authority header is - * suffixed with -shadow. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RequestMirrorPolicy request_mirror_policy = 10; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\RequestMirrorPolicy $var - * @return $this - */ - public function setRequestMirrorPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\RequestMirrorPolicy::class); - $this->request_mirror_policy = $var; - - return $this; - } - - /** - * The specification for allowing client side cross-origin requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.CorsPolicy cors_policy = 11; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\CorsPolicy|null - */ - public function getCorsPolicy() - { - return $this->cors_policy; - } - - public function hasCorsPolicy() - { - return isset($this->cors_policy); - } - - public function clearCorsPolicy() - { - unset($this->cors_policy); - } - - /** - * The specification for allowing client side cross-origin requests. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.CorsPolicy cors_policy = 11; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\CorsPolicy $var - * @return $this - */ - public function setCorsPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\CorsPolicy::class); - $this->cors_policy = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteAction::class, \Google\Cloud\NetworkServices\V1\HttpRoute_RouteAction::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteMatch.php deleted file mode 100644 index b8df819973f3..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteMatch.php +++ /dev/null @@ -1,290 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.RouteMatch - */ -class RouteMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies if prefix_match and full_path_match matches are case sensitive. - * The default value is false. - * - * Generated from protobuf field bool ignore_case = 4; - */ - protected $ignore_case = false; - /** - * Specifies a list of HTTP request headers to match against. ALL of the - * supplied headers must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.HeaderMatch headers = 5; - */ - private $headers; - /** - * Specifies a list of query parameters to match against. ALL of the query - * parameters must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.QueryParameterMatch query_parameters = 6; - */ - private $query_parameters; - protected $PathMatch; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $full_path_match - * The HTTP request path value should exactly match this value. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * @type string $prefix_match - * The HTTP request path value must begin with specified prefix_match. - * prefix_match must begin with a /. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * @type string $regex_match - * The HTTP request path value must satisfy the regular expression - * specified by regex_match after removing any query parameters and anchor - * supplied with the original URL. For regular expression grammar, please - * see https://github.com/google/re2/wiki/Syntax - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * @type bool $ignore_case - * Specifies if prefix_match and full_path_match matches are case sensitive. - * The default value is false. - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch>|\Google\Protobuf\Internal\RepeatedField $headers - * Specifies a list of HTTP request headers to match against. ALL of the - * supplied headers must be matched. - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute\QueryParameterMatch>|\Google\Protobuf\Internal\RepeatedField $query_parameters - * Specifies a list of query parameters to match against. ALL of the query - * parameters must be matched. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * The HTTP request path value should exactly match this value. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string full_path_match = 1; - * @return string - */ - public function getFullPathMatch() - { - return $this->readOneof(1); - } - - public function hasFullPathMatch() - { - return $this->hasOneof(1); - } - - /** - * The HTTP request path value should exactly match this value. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string full_path_match = 1; - * @param string $var - * @return $this - */ - public function setFullPathMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The HTTP request path value must begin with specified prefix_match. - * prefix_match must begin with a /. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string prefix_match = 2; - * @return string - */ - public function getPrefixMatch() - { - return $this->readOneof(2); - } - - public function hasPrefixMatch() - { - return $this->hasOneof(2); - } - - /** - * The HTTP request path value must begin with specified prefix_match. - * prefix_match must begin with a /. - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string prefix_match = 2; - * @param string $var - * @return $this - */ - public function setPrefixMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The HTTP request path value must satisfy the regular expression - * specified by regex_match after removing any query parameters and anchor - * supplied with the original URL. For regular expression grammar, please - * see https://github.com/google/re2/wiki/Syntax - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string regex_match = 3; - * @return string - */ - public function getRegexMatch() - { - return $this->readOneof(3); - } - - public function hasRegexMatch() - { - return $this->hasOneof(3); - } - - /** - * The HTTP request path value must satisfy the regular expression - * specified by regex_match after removing any query parameters and anchor - * supplied with the original URL. For regular expression grammar, please - * see https://github.com/google/re2/wiki/Syntax - * Only one of full_path_match, prefix_match, or regex_match should be - * used. - * - * Generated from protobuf field string regex_match = 3; - * @param string $var - * @return $this - */ - public function setRegexMatch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Specifies if prefix_match and full_path_match matches are case sensitive. - * The default value is false. - * - * Generated from protobuf field bool ignore_case = 4; - * @return bool - */ - public function getIgnoreCase() - { - return $this->ignore_case; - } - - /** - * Specifies if prefix_match and full_path_match matches are case sensitive. - * The default value is false. - * - * Generated from protobuf field bool ignore_case = 4; - * @param bool $var - * @return $this - */ - public function setIgnoreCase($var) - { - GPBUtil::checkBool($var); - $this->ignore_case = $var; - - return $this; - } - - /** - * Specifies a list of HTTP request headers to match against. ALL of the - * supplied headers must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.HeaderMatch headers = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHeaders() - { - return $this->headers; - } - - /** - * Specifies a list of HTTP request headers to match against. ALL of the - * supplied headers must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.HeaderMatch headers = 5; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute\HeaderMatch::class); - $this->headers = $arr; - - return $this; - } - - /** - * Specifies a list of query parameters to match against. ALL of the query - * parameters must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.QueryParameterMatch query_parameters = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQueryParameters() - { - return $this->query_parameters; - } - - /** - * Specifies a list of query parameters to match against. ALL of the query - * parameters must be matched. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.QueryParameterMatch query_parameters = 6; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute\QueryParameterMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQueryParameters($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute\QueryParameterMatch::class); - $this->query_parameters = $arr; - - return $this; - } - - /** - * @return string - */ - public function getPathMatch() - { - return $this->whichOneof("PathMatch"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteMatch::class, \Google\Cloud\NetworkServices\V1\HttpRoute_RouteMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteRule.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteRule.php deleted file mode 100644 index c81a5486d91d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/RouteRule.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.RouteRule - */ -class RouteRule extends \Google\Protobuf\Internal\Message -{ - /** - * A list of matches define conditions used for matching the rule against - * incoming HTTP requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. - * If no matches field is specified, this rule will unconditionally match - * traffic. - * If a default rule is desired to be configured, add a rule with no matches - * specified to the end of the rules list. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1; - */ - private $matches; - /** - * The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2; - */ - protected $action = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $matches - * A list of matches define conditions used for matching the rule against - * incoming HTTP requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. - * If no matches field is specified, this rule will unconditionally match - * traffic. - * If a default rule is desired to be configured, add a rule with no matches - * specified to the end of the rules list. - * @type \Google\Cloud\NetworkServices\V1\HttpRoute\RouteAction $action - * The detailed rule defining how to route matched traffic. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * A list of matches define conditions used for matching the rule against - * incoming HTTP requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. - * If no matches field is specified, this rule will unconditionally match - * traffic. - * If a default rule is desired to be configured, add a rule with no matches - * specified to the end of the rules list. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMatches() - { - return $this->matches; - } - - /** - * A list of matches define conditions used for matching the rule against - * incoming HTTP requests. Each match is independent, i.e. this rule will be - * matched if ANY one of the matches is satisfied. - * If no matches field is specified, this rule will unconditionally match - * traffic. - * If a default rule is desired to be configured, add a rule with no matches - * specified to the end of the rules list. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMatches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute\RouteMatch::class); - $this->matches = $arr; - - return $this; - } - - /** - * The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute\RouteAction|null - */ - public function getAction() - { - return $this->action; - } - - public function hasAction() - { - return isset($this->action); - } - - public function clearAction() - { - unset($this->action); - } - - /** - * The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute\RouteAction $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute\RouteAction::class); - $this->action = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteRule::class, \Google\Cloud\NetworkServices\V1\HttpRoute_RouteRule::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/URLRewrite.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/URLRewrite.php deleted file mode 100644 index a5668baf2c48..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/HttpRoute/URLRewrite.php +++ /dev/null @@ -1,113 +0,0 @@ -google.cloud.networkservices.v1.HttpRoute.URLRewrite - */ -class URLRewrite extends \Google\Protobuf\Internal\Message -{ - /** - * Prior to forwarding the request to the selected destination, the matching - * portion of the requests path is replaced by this value. - * - * Generated from protobuf field string path_prefix_rewrite = 1; - */ - protected $path_prefix_rewrite = ''; - /** - * Prior to forwarding the request to the selected destination, the requests - * host header is replaced by this value. - * - * Generated from protobuf field string host_rewrite = 2; - */ - protected $host_rewrite = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path_prefix_rewrite - * Prior to forwarding the request to the selected destination, the matching - * portion of the requests path is replaced by this value. - * @type string $host_rewrite - * Prior to forwarding the request to the selected destination, the requests - * host header is replaced by this value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Prior to forwarding the request to the selected destination, the matching - * portion of the requests path is replaced by this value. - * - * Generated from protobuf field string path_prefix_rewrite = 1; - * @return string - */ - public function getPathPrefixRewrite() - { - return $this->path_prefix_rewrite; - } - - /** - * Prior to forwarding the request to the selected destination, the matching - * portion of the requests path is replaced by this value. - * - * Generated from protobuf field string path_prefix_rewrite = 1; - * @param string $var - * @return $this - */ - public function setPathPrefixRewrite($var) - { - GPBUtil::checkString($var, True); - $this->path_prefix_rewrite = $var; - - return $this; - } - - /** - * Prior to forwarding the request to the selected destination, the requests - * host header is replaced by this value. - * - * Generated from protobuf field string host_rewrite = 2; - * @return string - */ - public function getHostRewrite() - { - return $this->host_rewrite; - } - - /** - * Prior to forwarding the request to the selected destination, the requests - * host header is replaced by this value. - * - * Generated from protobuf field string host_rewrite = 2; - * @param string $var - * @return $this - */ - public function setHostRewrite($var) - { - GPBUtil::checkString($var, True); - $this->host_rewrite = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(URLRewrite::class, \Google\Cloud\NetworkServices\V1\HttpRoute_URLRewrite::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbRouteExtension.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbRouteExtension.php deleted file mode 100644 index 9609aa638c89..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbRouteExtension.php +++ /dev/null @@ -1,462 +0,0 @@ -google.cloud.networkservices.v1.LbRouteExtension - */ -class LbRouteExtension extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Identifier. Name of the `LbRouteExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. A human-readable description of the resource. - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Set of labels associated with the `LbRouteExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LbRouteExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $forwarding_rules; - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - private $extension_chains; - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $load_balancing_scheme = 0; - /** - * Optional. The metadata provided here is included as part of the - * `metadata_context` (of type `google.protobuf.Struct`) in the - * `ProcessingRequest` message sent to the extension - * server. The metadata is available under the namespace - * `com.google.lb_route_extension.`. - * The following variables are supported in the metadata Struct: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Identifier. Name of the `LbRouteExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type string $description - * Optional. A human-readable description of the resource. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of labels associated with the `LbRouteExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * @type array|\Google\Protobuf\Internal\RepeatedField $forwarding_rules - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LbRouteExtension` resource per forwarding rule. - * @type array<\Google\Cloud\NetworkServices\V1\ExtensionChain>|\Google\Protobuf\Internal\RepeatedField $extension_chains - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * @type int $load_balancing_scheme - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * @type \Google\Protobuf\Struct $metadata - * Optional. The metadata provided here is included as part of the - * `metadata_context` (of type `google.protobuf.Struct`) in the - * `ProcessingRequest` message sent to the extension - * server. The metadata is available under the namespace - * `com.google.lb_route_extension.`. - * The following variables are supported in the metadata Struct: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. Identifier. Name of the `LbRouteExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Identifier. Name of the `LbRouteExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.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 timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. A human-readable description of the resource. - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A human-readable description of the resource. - * - * 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. Set of labels associated with the `LbRouteExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of labels associated with the `LbRouteExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LbRouteExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getForwardingRules() - { - return $this->forwarding_rules; - } - - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LbRouteExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setForwardingRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->forwarding_rules = $arr; - - return $this; - } - - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExtensionChains() - { - return $this->extension_chains; - } - - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\ExtensionChain>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExtensionChains($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\ExtensionChain::class); - $this->extension_chains = $arr; - - return $this; - } - - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getLoadBalancingScheme() - { - return $this->load_balancing_scheme; - } - - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setLoadBalancingScheme($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\LoadBalancingScheme::class); - $this->load_balancing_scheme = $var; - - return $this; - } - - /** - * Optional. The metadata provided here is included as part of the - * `metadata_context` (of type `google.protobuf.Struct`) in the - * `ProcessingRequest` message sent to the extension - * server. The metadata is available under the namespace - * `com.google.lb_route_extension.`. - * The following variables are supported in the metadata Struct: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Optional. The metadata provided here is included as part of the - * `metadata_context` (of type `google.protobuf.Struct`) in the - * `ProcessingRequest` message sent to the extension - * server. The metadata is available under the namespace - * `com.google.lb_route_extension.`. - * The following variables are supported in the metadata Struct: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbTrafficExtension.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbTrafficExtension.php deleted file mode 100644 index 250a492185ab..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LbTrafficExtension.php +++ /dev/null @@ -1,460 +0,0 @@ -google.cloud.networkservices.v1.LbTrafficExtension - */ -class LbTrafficExtension extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Identifier. Name of the `LbTrafficExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. A human-readable description of the resource. - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Set of labels associated with the `LbTrafficExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LBTrafficExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $forwarding_rules; - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - private $extension_chains; - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $load_balancing_scheme = 0; - /** - * Optional. The metadata provided here is included in the - * `ProcessingRequest.metadata_context.filter_metadata` map field. The - * metadata is available under the key - * `com.google.lb_traffic_extension.`. - * The following variables are supported in the metadata: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Identifier. Name of the `LbTrafficExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type string $description - * Optional. A human-readable description of the resource. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of labels associated with the `LbTrafficExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * @type array|\Google\Protobuf\Internal\RepeatedField $forwarding_rules - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LBTrafficExtension` resource per forwarding rule. - * @type array<\Google\Cloud\NetworkServices\V1\ExtensionChain>|\Google\Protobuf\Internal\RepeatedField $extension_chains - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * @type int $load_balancing_scheme - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * @type \Google\Protobuf\Struct $metadata - * Optional. The metadata provided here is included in the - * `ProcessingRequest.metadata_context.filter_metadata` map field. The - * metadata is available under the key - * `com.google.lb_traffic_extension.`. - * The following variables are supported in the metadata: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. Identifier. Name of the `LbTrafficExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Identifier. Name of the `LbTrafficExtension` resource in the - * following format: - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.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 timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. A human-readable description of the resource. - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A human-readable description of the resource. - * - * 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. Set of labels associated with the `LbTrafficExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of labels associated with the `LbTrafficExtension` resource. - * The format must comply with [the requirements for - * labels](https://cloud.google.com/compute/docs/labeling-resources#requirements) - * for Google Cloud resources. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LBTrafficExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getForwardingRules() - { - return $this->forwarding_rules; - } - - /** - * Required. A list of references to the forwarding rules to which this - * service extension is attached to. At least one forwarding rule is required. - * There can be only one `LBTrafficExtension` resource per forwarding rule. - * - * Generated from protobuf field repeated string forwarding_rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setForwardingRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->forwarding_rules = $arr; - - return $this; - } - - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExtensionChains() - { - return $this->extension_chains; - } - - /** - * Required. A set of ordered extension chains that contain the match - * conditions and extensions to execute. Match conditions for each extension - * chain are evaluated in sequence for a given request. The first extension - * chain that has a condition that matches the request is executed. - * Any subsequent extension chains do not execute. - * Limited to 5 extension chains per resource. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ExtensionChain extension_chains = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\ExtensionChain>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExtensionChains($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\ExtensionChain::class); - $this->extension_chains = $arr; - - return $this; - } - - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getLoadBalancingScheme() - { - return $this->load_balancing_scheme; - } - - /** - * Required. All backend services and forwarding rules referenced by this - * extension must share the same load balancing scheme. Supported values: - * `INTERNAL_MANAGED`, `EXTERNAL_MANAGED`. For more information, refer to - * [Choosing a load - * balancer](https://cloud.google.com/load-balancing/docs/backend-service). - * - * Generated from protobuf field .google.cloud.networkservices.v1.LoadBalancingScheme load_balancing_scheme = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setLoadBalancingScheme($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\NetworkServices\V1\LoadBalancingScheme::class); - $this->load_balancing_scheme = $var; - - return $this; - } - - /** - * Optional. The metadata provided here is included in the - * `ProcessingRequest.metadata_context.filter_metadata` map field. The - * metadata is available under the key - * `com.google.lb_traffic_extension.`. - * The following variables are supported in the metadata: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Optional. The metadata provided here is included in the - * `ProcessingRequest.metadata_context.filter_metadata` map field. The - * metadata is available under the key - * `com.google.lb_traffic_extension.`. - * The following variables are supported in the metadata: - * `{forwarding_rule_id}` - substituted with the forwarding rule's fully - * qualified resource name. - * - * Generated from protobuf field .google.protobuf.Struct metadata = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesRequest.php deleted file mode 100644 index 21810b6aea0d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesRequest.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.networkservices.v1.ListEndpointPoliciesRequest - */ -class ListEndpointPoliciesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the EndpointPolicies should - * be listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of EndpointPolicies to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListEndpointPoliciesResponse` - * Indicates that this is a continuation of a prior - * `ListEndpointPolicies` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the EndpointPolicies should - * be listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of EndpointPolicies to return per call. - * @type string $page_token - * The value returned by the last `ListEndpointPoliciesResponse` - * Indicates that this is a continuation of a prior - * `ListEndpointPolicies` call, and that the system should return the - * next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the EndpointPolicies should - * be listed, specified in the format `projects/*/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 project and location from which the EndpointPolicies should - * be listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of EndpointPolicies to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of EndpointPolicies to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListEndpointPoliciesResponse` - * Indicates that this is a continuation of a prior - * `ListEndpointPolicies` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListEndpointPoliciesResponse` - * Indicates that this is a continuation of a prior - * `ListEndpointPolicies` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesResponse.php deleted file mode 100644 index 05c64b8047f8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListEndpointPoliciesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListEndpointPoliciesResponse - */ -class ListEndpointPoliciesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of EndpointPolicy resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointPolicy endpoint_policies = 1; - */ - private $endpoint_policies; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\EndpointPolicy>|\Google\Protobuf\Internal\RepeatedField $endpoint_policies - * List of EndpointPolicy resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * List of EndpointPolicy resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointPolicy endpoint_policies = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEndpointPolicies() - { - return $this->endpoint_policies; - } - - /** - * List of EndpointPolicy resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.EndpointPolicy endpoint_policies = 1; - * @param array<\Google\Cloud\NetworkServices\V1\EndpointPolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEndpointPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\EndpointPolicy::class); - $this->endpoint_policies = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysRequest.php deleted file mode 100644 index 392d1e12e611..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListGatewaysRequest - */ -class ListGatewaysRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the Gateways should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of Gateways to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListGatewaysResponse` - * Indicates that this is a continuation of a prior `ListGateways` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the Gateways should be - * listed, specified in the format `projects/*/locations/*`. - * @type int $page_size - * Maximum number of Gateways to return per call. - * @type string $page_token - * The value returned by the last `ListGatewaysResponse` - * Indicates that this is a continuation of a prior `ListGateways` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the Gateways should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the Gateways should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of Gateways to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of Gateways to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListGatewaysResponse` - * Indicates that this is a continuation of a prior `ListGateways` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListGatewaysResponse` - * Indicates that this is a continuation of a prior `ListGateways` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysResponse.php deleted file mode 100644 index 4e2ad9ad2a55..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGatewaysResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListGatewaysResponse - */ -class ListGatewaysResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of Gateway resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Gateway gateways = 1; - */ - private $gateways; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\Gateway>|\Google\Protobuf\Internal\RepeatedField $gateways - * List of Gateway resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * List of Gateway resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Gateway gateways = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGateways() - { - return $this->gateways; - } - - /** - * List of Gateway resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Gateway gateways = 1; - * @param array<\Google\Cloud\NetworkServices\V1\Gateway>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\Gateway::class); - $this->gateways = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesRequest.php deleted file mode 100644 index 2e87d06f1647..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListGrpcRoutesRequest - */ -class ListGrpcRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the GrpcRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of GrpcRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListGrpcRoutesResponse` - * Indicates that this is a continuation of a prior `ListGrpcRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the GrpcRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of GrpcRoutes to return per call. - * @type string $page_token - * The value returned by the last `ListGrpcRoutesResponse` - * Indicates that this is a continuation of a prior `ListGrpcRoutes` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the GrpcRoutes should be - * listed, specified in the format `projects/*/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 project and location from which the GrpcRoutes should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of GrpcRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of GrpcRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListGrpcRoutesResponse` - * Indicates that this is a continuation of a prior `ListGrpcRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListGrpcRoutesResponse` - * Indicates that this is a continuation of a prior `ListGrpcRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesResponse.php deleted file mode 100644 index 25ae1ebe88f6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListGrpcRoutesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListGrpcRoutesResponse - */ -class ListGrpcRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of GrpcRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute grpc_routes = 1; - */ - private $grpc_routes; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\GrpcRoute>|\Google\Protobuf\Internal\RepeatedField $grpc_routes - * List of GrpcRoute resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * List of GrpcRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute grpc_routes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGrpcRoutes() - { - return $this->grpc_routes; - } - - /** - * List of GrpcRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.GrpcRoute grpc_routes = 1; - * @param array<\Google\Cloud\NetworkServices\V1\GrpcRoute>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGrpcRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\GrpcRoute::class); - $this->grpc_routes = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesRequest.php deleted file mode 100644 index c4373e5845c5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListHttpRoutesRequest - */ -class ListHttpRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the HttpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of HttpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListHttpRoutesResponse` - * Indicates that this is a continuation of a prior `ListHttpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the HttpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of HttpRoutes to return per call. - * @type string $page_token - * The value returned by the last `ListHttpRoutesResponse` - * Indicates that this is a continuation of a prior `ListHttpRoutes` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the HttpRoutes should be - * listed, specified in the format `projects/*/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 project and location from which the HttpRoutes should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of HttpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of HttpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListHttpRoutesResponse` - * Indicates that this is a continuation of a prior `ListHttpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListHttpRoutesResponse` - * Indicates that this is a continuation of a prior `ListHttpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesResponse.php deleted file mode 100644 index 121684e24a3e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListHttpRoutesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListHttpRoutesResponse - */ -class ListHttpRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of HttpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute http_routes = 1; - */ - private $http_routes; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\HttpRoute>|\Google\Protobuf\Internal\RepeatedField $http_routes - * List of HttpRoute resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * List of HttpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute http_routes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHttpRoutes() - { - return $this->http_routes; - } - - /** - * List of HttpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.HttpRoute http_routes = 1; - * @param array<\Google\Cloud\NetworkServices\V1\HttpRoute>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHttpRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\HttpRoute::class); - $this->http_routes = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsRequest.php deleted file mode 100644 index f9ecef198259..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsRequest.php +++ /dev/null @@ -1,215 +0,0 @@ -google.cloud.networkservices.v1.ListLbRouteExtensionsRequest - */ -class ListLbRouteExtensionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the `LbRouteExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks 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 that the server returns. - * - * 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the `LbRouteExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * @type int $page_size - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks an appropriate default. - * @type string $page_token - * Optional. A token identifying a page of results that the server returns. - * @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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the `LbRouteExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the `LbRouteExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks 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. The server might return fewer items than - * requested. If unspecified, the server picks 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 that the server returns. - * - * 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 that the server returns. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsResponse.php deleted file mode 100644 index eefc0f3e2d60..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbRouteExtensionsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.networkservices.v1.ListLbRouteExtensionsResponse - */ -class ListLbRouteExtensionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of `LbRouteExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbRouteExtension lb_route_extensions = 1; - */ - private $lb_route_extensions; - /** - * A token identifying a page of results that the server returns. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\LbRouteExtension>|\Google\Protobuf\Internal\RepeatedField $lb_route_extensions - * The list of `LbRouteExtension` resources. - * @type string $next_page_token - * A token identifying a page of results that the server returns. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * The list of `LbRouteExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbRouteExtension lb_route_extensions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLbRouteExtensions() - { - return $this->lb_route_extensions; - } - - /** - * The list of `LbRouteExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbRouteExtension lb_route_extensions = 1; - * @param array<\Google\Cloud\NetworkServices\V1\LbRouteExtension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLbRouteExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\LbRouteExtension::class); - $this->lb_route_extensions = $arr; - - return $this; - } - - /** - * A token identifying a page of results that the server returns. - * - * 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 that the server returns. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsRequest.php deleted file mode 100644 index 23db243c4023..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsRequest.php +++ /dev/null @@ -1,215 +0,0 @@ -google.cloud.networkservices.v1.ListLbTrafficExtensionsRequest - */ -class ListLbTrafficExtensionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the `LbTrafficExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks 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 that the server returns. - * - * 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the `LbTrafficExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * @type int $page_size - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks an appropriate default. - * @type string $page_token - * Optional. A token identifying a page of results that the server returns. - * @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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the `LbTrafficExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the `LbTrafficExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Requested page size. The server might return fewer items than - * requested. If unspecified, the server picks 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. The server might return fewer items than - * requested. If unspecified, the server picks 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 that the server returns. - * - * 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 that the server returns. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsResponse.php deleted file mode 100644 index f87a63f11b09..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListLbTrafficExtensionsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.networkservices.v1.ListLbTrafficExtensionsResponse - */ -class ListLbTrafficExtensionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of `LbTrafficExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extensions = 1; - */ - private $lb_traffic_extensions; - /** - * A token identifying a page of results that the server returns. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\LbTrafficExtension>|\Google\Protobuf\Internal\RepeatedField $lb_traffic_extensions - * The list of `LbTrafficExtension` resources. - * @type string $next_page_token - * A token identifying a page of results that the server returns. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * The list of `LbTrafficExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extensions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLbTrafficExtensions() - { - return $this->lb_traffic_extensions; - } - - /** - * The list of `LbTrafficExtension` resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extensions = 1; - * @param array<\Google\Cloud\NetworkServices\V1\LbTrafficExtension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLbTrafficExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\LbTrafficExtension::class); - $this->lb_traffic_extensions = $arr; - - return $this; - } - - /** - * A token identifying a page of results that the server returns. - * - * 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 that the server returns. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesRequest.php deleted file mode 100644 index a68f0aad5fab..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListMeshesRequest - */ -class ListMeshesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the Meshes should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of Meshes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListMeshesResponse` - * Indicates that this is a continuation of a prior `ListMeshes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the Meshes should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of Meshes to return per call. - * @type string $page_token - * The value returned by the last `ListMeshesResponse` - * Indicates that this is a continuation of a prior `ListMeshes` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the Meshes should be - * listed, specified in the format `projects/*/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 project and location from which the Meshes should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of Meshes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of Meshes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListMeshesResponse` - * Indicates that this is a continuation of a prior `ListMeshes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListMeshesResponse` - * Indicates that this is a continuation of a prior `ListMeshes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesResponse.php deleted file mode 100644 index 4fc4bf9fd178..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListMeshesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListMeshesResponse - */ -class ListMeshesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of Mesh resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Mesh meshes = 1; - */ - private $meshes; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\Mesh>|\Google\Protobuf\Internal\RepeatedField $meshes - * List of Mesh resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * List of Mesh resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Mesh meshes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMeshes() - { - return $this->meshes; - } - - /** - * List of Mesh resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.Mesh meshes = 1; - * @param array<\Google\Cloud\NetworkServices\V1\Mesh>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMeshes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\Mesh::class); - $this->meshes = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsRequest.php deleted file mode 100644 index de4c7e3221de..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListServiceBindingsRequest - */ -class ListServiceBindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the ServiceBindings should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of ServiceBindings to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListServiceBindingsResponse` - * Indicates that this is a continuation of a prior `ListRouters` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the ServiceBindings should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of ServiceBindings to return per call. - * @type string $page_token - * The value returned by the last `ListServiceBindingsResponse` - * Indicates that this is a continuation of a prior `ListRouters` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the ServiceBindings should be - * listed, specified in the format `projects/*/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 project and location from which the ServiceBindings should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of ServiceBindings to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of ServiceBindings to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListServiceBindingsResponse` - * Indicates that this is a continuation of a prior `ListRouters` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListServiceBindingsResponse` - * Indicates that this is a continuation of a prior `ListRouters` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsResponse.php deleted file mode 100644 index e1ebc8bef520..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListServiceBindingsResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListServiceBindingsResponse - */ -class ListServiceBindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of ServiceBinding resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ServiceBinding service_bindings = 1; - */ - private $service_bindings; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\ServiceBinding>|\Google\Protobuf\Internal\RepeatedField $service_bindings - * List of ServiceBinding resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * List of ServiceBinding resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ServiceBinding service_bindings = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getServiceBindings() - { - return $this->service_bindings; - } - - /** - * List of ServiceBinding resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.ServiceBinding service_bindings = 1; - * @param array<\Google\Cloud\NetworkServices\V1\ServiceBinding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setServiceBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\ServiceBinding::class); - $this->service_bindings = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesRequest.php deleted file mode 100644 index 703c0941b27a..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListTcpRoutesRequest - */ -class ListTcpRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the TcpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of TcpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListTcpRoutesResponse` - * Indicates that this is a continuation of a prior `ListTcpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the TcpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of TcpRoutes to return per call. - * @type string $page_token - * The value returned by the last `ListTcpRoutesResponse` - * Indicates that this is a continuation of a prior `ListTcpRoutes` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the TcpRoutes should be - * listed, specified in the format `projects/*/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 project and location from which the TcpRoutes should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of TcpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of TcpRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListTcpRoutesResponse` - * Indicates that this is a continuation of a prior `ListTcpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListTcpRoutesResponse` - * Indicates that this is a continuation of a prior `ListTcpRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesResponse.php deleted file mode 100644 index ed511f17c5f4..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTcpRoutesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListTcpRoutesResponse - */ -class ListTcpRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of TcpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute tcp_routes = 1; - */ - private $tcp_routes; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TcpRoute>|\Google\Protobuf\Internal\RepeatedField $tcp_routes - * List of TcpRoute resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * List of TcpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute tcp_routes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTcpRoutes() - { - return $this->tcp_routes; - } - - /** - * List of TcpRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute tcp_routes = 1; - * @param array<\Google\Cloud\NetworkServices\V1\TcpRoute>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTcpRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TcpRoute::class); - $this->tcp_routes = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesRequest.php deleted file mode 100644 index 1afc22c3f5fd..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.ListTlsRoutesRequest - */ -class ListTlsRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the TlsRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of TlsRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListTlsRoutesResponse` - * Indicates that this is a continuation of a prior `ListTlsRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the TlsRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @type int $page_size - * Maximum number of TlsRoutes to return per call. - * @type string $page_token - * The value returned by the last `ListTlsRoutesResponse` - * Indicates that this is a continuation of a prior `ListTlsRoutes` call, - * and that the system should return the next page of data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the TlsRoutes should be - * listed, specified in the format `projects/*/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 project and location from which the TlsRoutes should be - * listed, specified in the format `projects/*/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; - } - - /** - * Maximum number of TlsRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of TlsRoutes to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListTlsRoutesResponse` - * Indicates that this is a continuation of a prior `ListTlsRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListTlsRoutesResponse` - * Indicates that this is a continuation of a prior `ListTlsRoutes` call, - * and that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesResponse.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesResponse.php deleted file mode 100644 index baf951142c4e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ListTlsRoutesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.networkservices.v1.ListTlsRoutesResponse - */ -class ListTlsRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of TlsRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute tls_routes = 1; - */ - private $tls_routes; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TlsRoute>|\Google\Protobuf\Internal\RepeatedField $tls_routes - * List of TlsRoute resources. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * List of TlsRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute tls_routes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTlsRoutes() - { - return $this->tls_routes; - } - - /** - * List of TlsRoute resources. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute tls_routes = 1; - * @param array<\Google\Cloud\NetworkServices\V1\TlsRoute>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTlsRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TlsRoute::class); - $this->tls_routes = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LoadBalancingScheme.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LoadBalancingScheme.php deleted file mode 100644 index 263ab38300d8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/LoadBalancingScheme.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.networkservices.v1.LoadBalancingScheme - */ -class LoadBalancingScheme -{ - /** - * Default value. Do not use. - * - * Generated from protobuf enum LOAD_BALANCING_SCHEME_UNSPECIFIED = 0; - */ - const LOAD_BALANCING_SCHEME_UNSPECIFIED = 0; - /** - * Signifies that this is used for Internal HTTP(S) Load Balancing. - * - * Generated from protobuf enum INTERNAL_MANAGED = 1; - */ - const INTERNAL_MANAGED = 1; - /** - * Signifies that this is used for External Managed HTTP(S) Load - * Balancing. - * - * Generated from protobuf enum EXTERNAL_MANAGED = 2; - */ - const EXTERNAL_MANAGED = 2; - - private static $valueToName = [ - self::LOAD_BALANCING_SCHEME_UNSPECIFIED => 'LOAD_BALANCING_SCHEME_UNSPECIFIED', - self::INTERNAL_MANAGED => 'INTERNAL_MANAGED', - self::EXTERNAL_MANAGED => 'EXTERNAL_MANAGED', - ]; - - 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Mesh.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Mesh.php deleted file mode 100644 index 14d967fcf671..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/Mesh.php +++ /dev/null @@ -1,321 +0,0 @@ -google.cloud.networkservices.v1.Mesh - */ -class Mesh extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the Mesh resource. It matches pattern - * `projects/*/locations/global/meshes/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Set of label tags associated with the Mesh resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy - * to listen on the specified port of localhost (127.0.0.1) address. The - * SIDECAR proxy will expect all traffic to be redirected to this port - * regardless of its actual ip:port destination. If unset, a port '15001' is - * used as the interception port. This is applicable only for sidecar proxy - * deployments. - * - * Generated from protobuf field int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $interception_port = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the Mesh resource. It matches pattern - * `projects/*/locations/global/meshes/`. - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the Mesh resource. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type int $interception_port - * Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy - * to listen on the specified port of localhost (127.0.0.1) address. The - * SIDECAR proxy will expect all traffic to be redirected to this port - * regardless of its actual ip:port destination. If unset, a port '15001' is - * used as the interception port. This is applicable only for sidecar proxy - * deployments. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the Mesh resource. It matches pattern - * `projects/*/locations/global/meshes/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the Mesh resource. It matches pattern - * `projects/*/locations/global/meshes/`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. Set of label tags associated with the Mesh resource. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the Mesh resource. - * - * 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. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * 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; - } - - /** - * Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy - * to listen on the specified port of localhost (127.0.0.1) address. The - * SIDECAR proxy will expect all traffic to be redirected to this port - * regardless of its actual ip:port destination. If unset, a port '15001' is - * used as the interception port. This is applicable only for sidecar proxy - * deployments. - * - * Generated from protobuf field int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getInterceptionPort() - { - return $this->interception_port; - } - - /** - * Optional. If set to a valid TCP port (1-65535), instructs the SIDECAR proxy - * to listen on the specified port of localhost (127.0.0.1) address. The - * SIDECAR proxy will expect all traffic to be redirected to this port - * regardless of its actual ip:port destination. If unset, a port '15001' is - * used as the interception port. This is applicable only for sidecar proxy - * deployments. - * - * Generated from protobuf field int32 interception_port = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setInterceptionPort($var) - { - GPBUtil::checkInt32($var); - $this->interception_port = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/OperationMetadata.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/OperationMetadata.php deleted file mode 100644 index 36e7066401a5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/OperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.networkservices.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ServiceBinding.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ServiceBinding.php deleted file mode 100644 index 93e657a35992..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/ServiceBinding.php +++ /dev/null @@ -1,270 +0,0 @@ -google.cloud.networkservices.v1.ServiceBinding - */ -class ServiceBinding extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the ServiceBinding resource. It matches pattern - * `projects/*/locations/global/serviceBindings/service_binding_name`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Required. The full service directory service name of the format - * /projects/*/locations/*/namespaces/*/services/* - * - * Generated from protobuf field string service = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service = ''; - /** - * Optional. Set of label tags associated with the ServiceBinding resource. - * - * Generated from protobuf field map labels = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the ServiceBinding resource. It matches pattern - * `projects/*/locations/global/serviceBindings/service_binding_name`. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type string $service - * Required. The full service directory service name of the format - * /projects/*/locations/*/namespaces/*/services/* - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the ServiceBinding resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\ServiceBinding::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the ServiceBinding resource. It matches pattern - * `projects/*/locations/global/serviceBindings/service_binding_name`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the ServiceBinding resource. It matches pattern - * `projects/*/locations/global/serviceBindings/service_binding_name`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 2 [(.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 timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Required. The full service directory service name of the format - * /projects/*/locations/*/namespaces/*/services/* - * - * Generated from protobuf field string service = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * Required. The full service directory service name of the format - * /projects/*/locations/*/namespaces/*/services/* - * - * Generated from protobuf field string service = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * Optional. Set of label tags associated with the ServiceBinding resource. - * - * Generated from protobuf field map labels = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the ServiceBinding resource. - * - * Generated from protobuf field map labels = 7 [(.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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute.php deleted file mode 100644 index 00624114cb2f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute.php +++ /dev/null @@ -1,404 +0,0 @@ -google.cloud.networkservices.v1.TcpRoute - */ -class TcpRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the TcpRoute resource. It matches pattern - * `projects/*/locations/global/tcpRoutes/tcp_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $rules; - /** - * Optional. Meshes defines a list of meshes this TcpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $meshes; - /** - * Optional. Gateways defines a list of gateways this TcpRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $gateways; - /** - * Optional. Set of label tags associated with the TcpRoute resource. - * - * 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 - * Required. Name of the TcpRoute resource. It matches pattern - * `projects/*/locations/global/tcpRoutes/tcp_route_name>`. - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $rules - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * @type array|\Google\Protobuf\Internal\RepeatedField $meshes - * Optional. Meshes defines a list of meshes this TcpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * @type array|\Google\Protobuf\Internal\RepeatedField $gateways - * Optional. Gateways defines a list of gateways this TcpRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Set of label tags associated with the TcpRoute resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the TcpRoute resource. It matches pattern - * `projects/*/locations/global/tcpRoutes/tcp_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the TcpRoute resource. It matches pattern - * `projects/*/locations/global/tcpRoutes/tcp_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * 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; - } - - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRules() - { - return $this->rules; - } - - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TcpRoute\RouteRule::class); - $this->rules = $arr; - - return $this; - } - - /** - * Optional. Meshes defines a list of meshes this TcpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMeshes() - { - return $this->meshes; - } - - /** - * Optional. Meshes defines a list of meshes this TcpRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMeshes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->meshes = $arr; - - return $this; - } - - /** - * Optional. Gateways defines a list of gateways this TcpRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGateways() - { - return $this->gateways; - } - - /** - * Optional. Gateways defines a list of gateways this TcpRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->gateways = $arr; - - return $this; - } - - /** - * Optional. Set of label tags associated with the TcpRoute resource. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Set of label tags associated with the TcpRoute resource. - * - * 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteAction.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteAction.php deleted file mode 100644 index b2e0e11f070f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteAction.php +++ /dev/null @@ -1,120 +0,0 @@ -google.cloud.networkservices.v1.TcpRoute.RouteAction - */ -class RouteAction extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The destination services to which traffic should be forwarded. - * At least one destination service is required. Only one of route - * destination or original destination can be set. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $destinations; - /** - * Optional. If true, Router will use the destination IP and port of the - * original connection as the destination of the request. Default is false. - * Only one of route destinations or original destination can be set. - * - * Generated from protobuf field bool original_destination = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $original_destination = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteDestination>|\Google\Protobuf\Internal\RepeatedField $destinations - * Optional. The destination services to which traffic should be forwarded. - * At least one destination service is required. Only one of route - * destination or original destination can be set. - * @type bool $original_destination - * Optional. If true, Router will use the destination IP and port of the - * original connection as the destination of the request. Default is false. - * Only one of route destinations or original destination can be set. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The destination services to which traffic should be forwarded. - * At least one destination service is required. Only one of route - * destination or original destination can be set. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDestinations() - { - return $this->destinations; - } - - /** - * Optional. The destination services to which traffic should be forwarded. - * At least one destination service is required. Only one of route - * destination or original destination can be set. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteDestination>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDestinations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TcpRoute\RouteDestination::class); - $this->destinations = $arr; - - return $this; - } - - /** - * Optional. If true, Router will use the destination IP and port of the - * original connection as the destination of the request. Default is false. - * Only one of route destinations or original destination can be set. - * - * Generated from protobuf field bool original_destination = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getOriginalDestination() - { - return $this->original_destination; - } - - /** - * Optional. If true, Router will use the destination IP and port of the - * original connection as the destination of the request. Default is false. - * Only one of route destinations or original destination can be set. - * - * Generated from protobuf field bool original_destination = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setOriginalDestination($var) - { - GPBUtil::checkBool($var); - $this->original_destination = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteAction::class, \Google\Cloud\NetworkServices\V1\TcpRoute_RouteAction::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteDestination.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteDestination.php deleted file mode 100644 index e663cca2b90f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteDestination.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.networkservices.v1.TcpRoute.RouteDestination - */ -class RouteDestination extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $service_name = ''; - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $weight = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The URL of a BackendService to route traffic to. - * @type int $weight - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getWeight() - { - return $this->weight; - } - - /** - * Optional. Specifies the proportion of requests forwarded to the backend - * referenced by the serviceName field. This is computed as: - * - weight/Sum(weights in this destination list). - * For non-zero values, there may be some epsilon from the exact proportion - * defined here depending on the precision an implementation supports. - * If only one serviceName is specified and it has a weight greater than 0, - * 100% of the traffic is forwarded to that backend. - * If weights are specified for any one service name, they need to be - * specified for all of them. - * If weights are unspecified for all services, then, traffic is distributed - * in equal proportions to all of them. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setWeight($var) - { - GPBUtil::checkInt32($var); - $this->weight = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteDestination::class, \Google\Cloud\NetworkServices\V1\TcpRoute_RouteDestination::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteMatch.php deleted file mode 100644 index a084049f5c79..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteMatch.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.networkservices.v1.TcpRoute.RouteMatch - */ -class RouteMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Must be specified in the CIDR range format. A CIDR range - * consists of an IP Address and a prefix length to construct the subnet - * mask. By default, the prefix length is 32 (i.e. matches a single IP - * address). Only IPV4 addresses are supported. - * Examples: - * "10.0.0.1" - matches against this exact IP address. - * "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet - * and 255.255.255.0 mask. - * "0.0.0.0/0" - matches against any IP address'. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $address = ''; - /** - * Required. Specifies the destination port to match against. - * - * Generated from protobuf field string port = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $port = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $address - * Required. Must be specified in the CIDR range format. A CIDR range - * consists of an IP Address and a prefix length to construct the subnet - * mask. By default, the prefix length is 32 (i.e. matches a single IP - * address). Only IPV4 addresses are supported. - * Examples: - * "10.0.0.1" - matches against this exact IP address. - * "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet - * and 255.255.255.0 mask. - * "0.0.0.0/0" - matches against any IP address'. - * @type string $port - * Required. Specifies the destination port to match against. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. Must be specified in the CIDR range format. A CIDR range - * consists of an IP Address and a prefix length to construct the subnet - * mask. By default, the prefix length is 32 (i.e. matches a single IP - * address). Only IPV4 addresses are supported. - * Examples: - * "10.0.0.1" - matches against this exact IP address. - * "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet - * and 255.255.255.0 mask. - * "0.0.0.0/0" - matches against any IP address'. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAddress() - { - return $this->address; - } - - /** - * Required. Must be specified in the CIDR range format. A CIDR range - * consists of an IP Address and a prefix length to construct the subnet - * mask. By default, the prefix length is 32 (i.e. matches a single IP - * address). Only IPV4 addresses are supported. - * Examples: - * "10.0.0.1" - matches against this exact IP address. - * "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet - * and 255.255.255.0 mask. - * "0.0.0.0/0" - matches against any IP address'. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAddress($var) - { - GPBUtil::checkString($var, True); - $this->address = $var; - - return $this; - } - - /** - * Required. Specifies the destination port to match against. - * - * Generated from protobuf field string port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPort() - { - return $this->port; - } - - /** - * Required. Specifies the destination port to match against. - * - * Generated from protobuf field string port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPort($var) - { - GPBUtil::checkString($var, True); - $this->port = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteMatch::class, \Google\Cloud\NetworkServices\V1\TcpRoute_RouteMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteRule.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteRule.php deleted file mode 100644 index 9653ee3d112e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TcpRoute/RouteRule.php +++ /dev/null @@ -1,127 +0,0 @@ -google.cloud.networkservices.v1.TcpRoute.RouteRule - */ -class RouteRule extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. If no - * routeMatch field is specified, this rule will unconditionally match - * traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $matches; - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $action = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $matches - * Optional. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. If no - * routeMatch field is specified, this rule will unconditionally match - * traffic. - * @type \Google\Cloud\NetworkServices\V1\TcpRoute\RouteAction $action - * Required. The detailed rule defining how to route matched traffic. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. If no - * routeMatch field is specified, this rule will unconditionally match - * traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMatches() - { - return $this->matches; - } - - /** - * Optional. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. If no - * routeMatch field is specified, this rule will unconditionally match - * traffic. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\NetworkServices\V1\TcpRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMatches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TcpRoute\RouteMatch::class); - $this->matches = $arr; - - return $this; - } - - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TcpRoute\RouteAction|null - */ - public function getAction() - { - return $this->action; - } - - public function hasAction() - { - return isset($this->action); - } - - public function clearAction() - { - unset($this->action); - } - - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TcpRoute\RouteAction $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TcpRoute\RouteAction::class); - $this->action = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteRule::class, \Google\Cloud\NetworkServices\V1\TcpRoute_RouteRule::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute.php deleted file mode 100644 index 9d44cf7d5e26..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute.php +++ /dev/null @@ -1,370 +0,0 @@ -google.cloud.networkservices.v1.TlsRoute - */ -class TlsRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the TlsRoute resource. It matches pattern - * `projects/*/locations/global/tlsRoutes/tls_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $self_link = ''; - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp when the resource was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $rules; - /** - * Optional. Meshes defines a list of meshes this TlsRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 6 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $meshes; - /** - * Optional. Gateways defines a list of gateways this TlsRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - private $gateways; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the TlsRoute resource. It matches pattern - * `projects/*/locations/global/tlsRoutes/tls_route_name>`. - * @type string $self_link - * Output only. Server-defined URL of this resource - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The timestamp when the resource was updated. - * @type string $description - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * @type array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $rules - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * @type array|\Google\Protobuf\Internal\RepeatedField $meshes - * Optional. Meshes defines a list of meshes this TlsRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * @type array|\Google\Protobuf\Internal\RepeatedField $gateways - * Optional. Gateways defines a list of gateways this TlsRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the TlsRoute resource. It matches pattern - * `projects/*/locations/global/tlsRoutes/tls_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the TlsRoute resource. It matches pattern - * `projects/*/locations/global/tlsRoutes/tls_route_name>`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getSelfLink() - { - return $this->self_link; - } - - /** - * Output only. Server-defined URL of this resource - * - * Generated from protobuf field string self_link = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setSelfLink($var) - { - GPBUtil::checkString($var, True); - $this->self_link = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp when the resource was updated. - * - * 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 timestamp when the resource was updated. - * - * 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. A free-text description of the resource. Max length 1024 - * characters. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A free-text description of the resource. Max length 1024 - * characters. - * - * 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; - } - - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRules() - { - return $this->rules; - } - - /** - * Required. Rules that define how traffic is routed and handled. At least one - * RouteRule must be supplied. If there are multiple rules then the action - * taken will be the first rule to match. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteRule rules = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TlsRoute\RouteRule::class); - $this->rules = $arr; - - return $this; - } - - /** - * Optional. Meshes defines a list of meshes this TlsRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 6 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMeshes() - { - return $this->meshes; - } - - /** - * Optional. Meshes defines a list of meshes this TlsRoute is attached to, as - * one of the routing rules to route the requests served by the mesh. - * Each mesh reference should match the pattern: - * `projects/*/locations/global/meshes/` - * The attached Mesh should be of a type SIDECAR - * - * Generated from protobuf field repeated string meshes = 6 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMeshes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->meshes = $arr; - - return $this; - } - - /** - * Optional. Gateways defines a list of gateways this TlsRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGateways() - { - return $this->gateways; - } - - /** - * Optional. Gateways defines a list of gateways this TlsRoute is attached to, - * as one of the routing rules to route the requests served by the gateway. - * Each gateway reference should match the pattern: - * `projects/*/locations/global/gateways/` - * - * Generated from protobuf field repeated string gateways = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->gateways = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteAction.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteAction.php deleted file mode 100644 index a59aab54d550..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteAction.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.networkservices.v1.TlsRoute.RouteAction - */ -class RouteAction extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The destination services to which traffic should be forwarded. - * At least one destination service is required. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $destinations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteDestination>|\Google\Protobuf\Internal\RepeatedField $destinations - * Required. The destination services to which traffic should be forwarded. - * At least one destination service is required. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The destination services to which traffic should be forwarded. - * At least one destination service is required. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDestinations() - { - return $this->destinations; - } - - /** - * Required. The destination services to which traffic should be forwarded. - * At least one destination service is required. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteDestination destinations = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteDestination>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDestinations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TlsRoute\RouteDestination::class); - $this->destinations = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteAction::class, \Google\Cloud\NetworkServices\V1\TlsRoute_RouteAction::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteDestination.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteDestination.php deleted file mode 100644 index 804ee9ad6ef1..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteDestination.php +++ /dev/null @@ -1,116 +0,0 @@ -google.cloud.networkservices.v1.TlsRoute.RouteDestination - */ -class RouteDestination extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $service_name = ''; - /** - * Optional. Specifies the proportion of requests forwareded to the backend - * referenced by the service_name field. This is computed as: - * - weight/Sum(weights in destinations) - * Weights in all destinations does not need to sum up to 100. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $weight = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The URL of a BackendService to route traffic to. - * @type int $weight - * Optional. Specifies the proportion of requests forwareded to the backend - * referenced by the service_name field. This is computed as: - * - weight/Sum(weights in destinations) - * Weights in all destinations does not need to sum up to 100. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The URL of a BackendService to route traffic to. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Optional. Specifies the proportion of requests forwareded to the backend - * referenced by the service_name field. This is computed as: - * - weight/Sum(weights in destinations) - * Weights in all destinations does not need to sum up to 100. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getWeight() - { - return $this->weight; - } - - /** - * Optional. Specifies the proportion of requests forwareded to the backend - * referenced by the service_name field. This is computed as: - * - weight/Sum(weights in destinations) - * Weights in all destinations does not need to sum up to 100. - * - * Generated from protobuf field int32 weight = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setWeight($var) - { - GPBUtil::checkInt32($var); - $this->weight = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteDestination::class, \Google\Cloud\NetworkServices\V1\TlsRoute_RouteDestination::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteMatch.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteMatch.php deleted file mode 100644 index a9c60595ff5f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteMatch.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.networkservices.v1.TlsRoute.RouteMatch - */ -class RouteMatch extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. SNI (server name indicator) to match against. - * SNI will be matched against all wildcard domains, i.e. `www.example.com` - * will be first matched against `www.example.com`, then `*.example.com`, - * then `*.com.` - * Partial wildcards are not supported, and values like *w.example.com are - * invalid. - * At least one of sni_host and alpn is required. - * Up to 5 sni hosts across all matches can be set. - * - * Generated from protobuf field repeated string sni_host = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $sni_host; - /** - * Optional. ALPN (Application-Layer Protocol Negotiation) to match against. - * Examples: "http/1.1", "h2". - * At least one of sni_host and alpn is required. - * Up to 5 alpns across all matches can be set. - * - * Generated from protobuf field repeated string alpn = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $alpn; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $sni_host - * Optional. SNI (server name indicator) to match against. - * SNI will be matched against all wildcard domains, i.e. `www.example.com` - * will be first matched against `www.example.com`, then `*.example.com`, - * then `*.com.` - * Partial wildcards are not supported, and values like *w.example.com are - * invalid. - * At least one of sni_host and alpn is required. - * Up to 5 sni hosts across all matches can be set. - * @type array|\Google\Protobuf\Internal\RepeatedField $alpn - * Optional. ALPN (Application-Layer Protocol Negotiation) to match against. - * Examples: "http/1.1", "h2". - * At least one of sni_host and alpn is required. - * Up to 5 alpns across all matches can be set. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. SNI (server name indicator) to match against. - * SNI will be matched against all wildcard domains, i.e. `www.example.com` - * will be first matched against `www.example.com`, then `*.example.com`, - * then `*.com.` - * Partial wildcards are not supported, and values like *w.example.com are - * invalid. - * At least one of sni_host and alpn is required. - * Up to 5 sni hosts across all matches can be set. - * - * Generated from protobuf field repeated string sni_host = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSniHost() - { - return $this->sni_host; - } - - /** - * Optional. SNI (server name indicator) to match against. - * SNI will be matched against all wildcard domains, i.e. `www.example.com` - * will be first matched against `www.example.com`, then `*.example.com`, - * then `*.com.` - * Partial wildcards are not supported, and values like *w.example.com are - * invalid. - * At least one of sni_host and alpn is required. - * Up to 5 sni hosts across all matches can be set. - * - * Generated from protobuf field repeated string sni_host = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSniHost($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->sni_host = $arr; - - return $this; - } - - /** - * Optional. ALPN (Application-Layer Protocol Negotiation) to match against. - * Examples: "http/1.1", "h2". - * At least one of sni_host and alpn is required. - * Up to 5 alpns across all matches can be set. - * - * Generated from protobuf field repeated string alpn = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAlpn() - { - return $this->alpn; - } - - /** - * Optional. ALPN (Application-Layer Protocol Negotiation) to match against. - * Examples: "http/1.1", "h2". - * At least one of sni_host and alpn is required. - * Up to 5 alpns across all matches can be set. - * - * Generated from protobuf field repeated string alpn = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAlpn($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->alpn = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteMatch::class, \Google\Cloud\NetworkServices\V1\TlsRoute_RouteMatch::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteRule.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteRule.php deleted file mode 100644 index 639817fa9d0d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TlsRoute/RouteRule.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.networkservices.v1.TlsRoute.RouteRule - */ -class RouteRule extends \Google\Protobuf\Internal\Message -{ - /** - * Required. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $matches; - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $action = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $matches - * Required. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. - * @type \Google\Cloud\NetworkServices\V1\TlsRoute\RouteAction $action - * Required. The detailed rule defining how to route matched traffic. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Required. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMatches() - { - return $this->matches; - } - - /** - * Required. RouteMatch defines the predicate used to match requests to a - * given action. Multiple match types are "OR"ed for evaluation. - * - * Generated from protobuf field repeated .google.cloud.networkservices.v1.TlsRoute.RouteMatch matches = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\NetworkServices\V1\TlsRoute\RouteMatch>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMatches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\NetworkServices\V1\TlsRoute\RouteMatch::class); - $this->matches = $arr; - - return $this; - } - - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TlsRoute\RouteAction|null - */ - public function getAction() - { - return $this->action; - } - - public function hasAction() - { - return isset($this->action); - } - - public function clearAction() - { - unset($this->action); - } - - /** - * Required. The detailed rule defining how to route matched traffic. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute.RouteAction action = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TlsRoute\RouteAction $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TlsRoute\RouteAction::class); - $this->action = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RouteRule::class, \Google\Cloud\NetworkServices\V1\TlsRoute_RouteRule::class); - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TrafficPortSelector.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TrafficPortSelector.php deleted file mode 100644 index 409d32c196e4..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/TrafficPortSelector.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.networkservices.v1.TrafficPortSelector - */ -class TrafficPortSelector extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A list of ports. Can be port numbers or port range - * (example, [80-90] specifies all ports from 80 to 90, including - * 80 and 90) or named ports or * to specify all ports. If the - * list is empty, all ports are selected. - * - * Generated from protobuf field repeated string ports = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $ports; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $ports - * Optional. A list of ports. Can be port numbers or port range - * (example, [80-90] specifies all ports from 80 to 90, including - * 80 and 90) or named ports or * to specify all ports. If the - * list is empty, all ports are selected. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A list of ports. Can be port numbers or port range - * (example, [80-90] specifies all ports from 80 to 90, including - * 80 and 90) or named ports or * to specify all ports. If the - * list is empty, all ports are selected. - * - * Generated from protobuf field repeated string ports = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPorts() - { - return $this->ports; - } - - /** - * Optional. A list of ports. Can be port numbers or port range - * (example, [80-90] specifies all ports from 80 to 90, including - * 80 and 90) or named ports or * to specify all ports. If the - * list is empty, all ports are selected. - * - * Generated from protobuf field repeated string ports = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ports = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateEndpointPolicyRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateEndpointPolicyRequest.php deleted file mode 100644 index 740ea6a28f2f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateEndpointPolicyRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateEndpointPolicyRequest - */ -class UpdateEndpointPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * EndpointPolicy 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated EndpointPolicy resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $endpoint_policy = null; - - /** - * 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 - * EndpointPolicy 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\NetworkServices\V1\EndpointPolicy $endpoint_policy - * Required. Updated EndpointPolicy resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\EndpointPolicy::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * EndpointPolicy 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) = 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 - * EndpointPolicy 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) = 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. Updated EndpointPolicy resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\EndpointPolicy|null - */ - public function getEndpointPolicy() - { - return $this->endpoint_policy; - } - - public function hasEndpointPolicy() - { - return isset($this->endpoint_policy); - } - - public function clearEndpointPolicy() - { - unset($this->endpoint_policy); - } - - /** - * Required. Updated EndpointPolicy resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.EndpointPolicy endpoint_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\EndpointPolicy $var - * @return $this - */ - public function setEndpointPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\EndpointPolicy::class); - $this->endpoint_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGatewayRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGatewayRequest.php deleted file mode 100644 index 1e79d3c2758d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGatewayRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateGatewayRequest - */ -class UpdateGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Gateway 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated Gateway resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $gateway = null; - - /** - * 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 - * Gateway 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\NetworkServices\V1\Gateway $gateway - * Required. Updated Gateway resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Gateway::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Gateway 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) = 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 - * Gateway 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) = 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. Updated Gateway resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\Gateway|null - */ - public function getGateway() - { - return $this->gateway; - } - - public function hasGateway() - { - return isset($this->gateway); - } - - public function clearGateway() - { - unset($this->gateway); - } - - /** - * Required. Updated Gateway resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Gateway gateway = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\Gateway $var - * @return $this - */ - public function setGateway($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\Gateway::class); - $this->gateway = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGrpcRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGrpcRouteRequest.php deleted file mode 100644 index 5411ee2c11a8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateGrpcRouteRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateGrpcRouteRequest - */ -class UpdateGrpcRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * GrpcRoute 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated GrpcRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $grpc_route = null; - - /** - * 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 - * GrpcRoute 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\NetworkServices\V1\GrpcRoute $grpc_route - * Required. Updated GrpcRoute resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\GrpcRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * GrpcRoute 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) = 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 - * GrpcRoute 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) = 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. Updated GrpcRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute|null - */ - public function getGrpcRoute() - { - return $this->grpc_route; - } - - public function hasGrpcRoute() - { - return isset($this->grpc_route); - } - - public function clearGrpcRoute() - { - unset($this->grpc_route); - } - - /** - * Required. Updated GrpcRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.GrpcRoute grpc_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\GrpcRoute $var - * @return $this - */ - public function setGrpcRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\GrpcRoute::class); - $this->grpc_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateHttpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateHttpRouteRequest.php deleted file mode 100644 index 292e9c1af9d9..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateHttpRouteRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateHttpRouteRequest - */ -class UpdateHttpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * HttpRoute 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated HttpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $http_route = null; - - /** - * 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 - * HttpRoute 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\NetworkServices\V1\HttpRoute $http_route - * Required. Updated HttpRoute resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\HttpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * HttpRoute 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) = 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 - * HttpRoute 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) = 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. Updated HttpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\HttpRoute|null - */ - public function getHttpRoute() - { - return $this->http_route; - } - - public function hasHttpRoute() - { - return isset($this->http_route); - } - - public function clearHttpRoute() - { - unset($this->http_route); - } - - /** - * Required. Updated HttpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.HttpRoute http_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\HttpRoute $var - * @return $this - */ - public function setHttpRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\HttpRoute::class); - $this->http_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbRouteExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbRouteExtensionRequest.php deleted file mode 100644 index ec0253dd7b40..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbRouteExtensionRequest.php +++ /dev/null @@ -1,211 +0,0 @@ -google.cloud.networkservices.v1.UpdateLbRouteExtensionRequest - */ -class UpdateLbRouteExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Used to specify the fields to be overwritten in the - * `LbRouteExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. `LbRouteExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_route_extension = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. Used to specify the fields to be overwritten in the - * `LbRouteExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * @type \Google\Cloud\NetworkServices\V1\LbRouteExtension $lb_route_extension - * Required. `LbRouteExtension` 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Used to specify the fields to be overwritten in the - * `LbRouteExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * 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. Used to specify the fields to be overwritten in the - * `LbRouteExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * 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. `LbRouteExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\LbRouteExtension|null - */ - public function getLbRouteExtension() - { - return $this->lb_route_extension; - } - - public function hasLbRouteExtension() - { - return isset($this->lb_route_extension); - } - - public function clearLbRouteExtension() - { - unset($this->lb_route_extension); - } - - /** - * Required. `LbRouteExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbRouteExtension lb_route_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\LbRouteExtension $var - * @return $this - */ - public function setLbRouteExtension($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\LbRouteExtension::class); - $this->lb_route_extension = $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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbTrafficExtensionRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbTrafficExtensionRequest.php deleted file mode 100644 index 808280a78d2e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateLbTrafficExtensionRequest.php +++ /dev/null @@ -1,211 +0,0 @@ -google.cloud.networkservices.v1.UpdateLbTrafficExtensionRequest - */ -class UpdateLbTrafficExtensionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Used to specify the fields to be overwritten in the - * `LbTrafficExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. `LbTrafficExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lb_traffic_extension = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. Used to specify the fields to be overwritten in the - * `LbTrafficExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * @type \Google\Cloud\NetworkServices\V1\LbTrafficExtension $lb_traffic_extension - * Required. `LbTrafficExtension` 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating 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\Networkservices\V1\Dep::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Used to specify the fields to be overwritten in the - * `LbTrafficExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * 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. Used to specify the fields to be overwritten in the - * `LbTrafficExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * - * 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. `LbTrafficExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\LbTrafficExtension|null - */ - public function getLbTrafficExtension() - { - return $this->lb_traffic_extension; - } - - public function hasLbTrafficExtension() - { - return isset($this->lb_traffic_extension); - } - - public function clearLbTrafficExtension() - { - unset($this->lb_traffic_extension); - } - - /** - * Required. `LbTrafficExtension` resource being updated. - * - * Generated from protobuf field .google.cloud.networkservices.v1.LbTrafficExtension lb_traffic_extension = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\LbTrafficExtension $var - * @return $this - */ - public function setLbTrafficExtension($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\LbTrafficExtension::class); - $this->lb_traffic_extension = $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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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 can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be 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/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateMeshRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateMeshRequest.php deleted file mode 100644 index ce964500953b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateMeshRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateMeshRequest - */ -class UpdateMeshRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Mesh 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated Mesh resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mesh = null; - - /** - * 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 - * Mesh 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\NetworkServices\V1\Mesh $mesh - * Required. Updated Mesh resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\Mesh::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Mesh 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) = 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 - * Mesh 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) = 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. Updated Mesh resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\Mesh|null - */ - public function getMesh() - { - return $this->mesh; - } - - public function hasMesh() - { - return isset($this->mesh); - } - - public function clearMesh() - { - unset($this->mesh); - } - - /** - * Required. Updated Mesh resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.Mesh mesh = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\Mesh $var - * @return $this - */ - public function setMesh($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\Mesh::class); - $this->mesh = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTcpRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTcpRouteRequest.php deleted file mode 100644 index 6b041d9abb14..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTcpRouteRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateTcpRouteRequest - */ -class UpdateTcpRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * TcpRoute 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated TcpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tcp_route = null; - - /** - * 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 - * TcpRoute 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\NetworkServices\V1\TcpRoute $tcp_route - * Required. Updated TcpRoute resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TcpRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * TcpRoute 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) = 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 - * TcpRoute 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) = 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. Updated TcpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TcpRoute|null - */ - public function getTcpRoute() - { - return $this->tcp_route; - } - - public function hasTcpRoute() - { - return isset($this->tcp_route); - } - - public function clearTcpRoute() - { - unset($this->tcp_route); - } - - /** - * Required. Updated TcpRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TcpRoute tcp_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TcpRoute $var - * @return $this - */ - public function setTcpRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TcpRoute::class); - $this->tcp_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTlsRouteRequest.php b/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTlsRouteRequest.php deleted file mode 100644 index ad8536d49340..000000000000 --- a/owl-bot-staging/NetworkServices/v1/proto/src/Google/Cloud/NetworkServices/V1/UpdateTlsRouteRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.networkservices.v1.UpdateTlsRouteRequest - */ -class UpdateTlsRouteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * TlsRoute 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) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. Updated TlsRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tls_route = null; - - /** - * 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 - * TlsRoute 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\NetworkServices\V1\TlsRoute $tls_route - * Required. Updated TlsRoute resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Networkservices\V1\TlsRoute::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * TlsRoute 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) = 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 - * TlsRoute 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) = 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. Updated TlsRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\NetworkServices\V1\TlsRoute|null - */ - public function getTlsRoute() - { - return $this->tls_route; - } - - public function hasTlsRoute() - { - return isset($this->tls_route); - } - - public function clearTlsRoute() - { - unset($this->tls_route); - } - - /** - * Required. Updated TlsRoute resource. - * - * Generated from protobuf field .google.cloud.networkservices.v1.TlsRoute tls_route = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\NetworkServices\V1\TlsRoute $var - * @return $this - */ - public function setTlsRoute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\NetworkServices\V1\TlsRoute::class); - $this->tls_route = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_route_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_route_extension.php deleted file mode 100644 index 598214c9eed5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_route_extension.php +++ /dev/null @@ -1,175 +0,0 @@ -setCelExpression($lbRouteExtensionExtensionChainsMatchConditionCelExpression); - $extension = (new Extension()) - ->setName($lbRouteExtensionExtensionChainsExtensionsName) - ->setService($lbRouteExtensionExtensionChainsExtensionsService); - $lbRouteExtensionExtensionChainsExtensions = [$extension,]; - $extensionChain = (new ExtensionChain()) - ->setName($lbRouteExtensionExtensionChainsName) - ->setMatchCondition($lbRouteExtensionExtensionChainsMatchCondition) - ->setExtensions($lbRouteExtensionExtensionChainsExtensions); - $lbRouteExtensionExtensionChains = [$extensionChain,]; - $lbRouteExtension = (new LbRouteExtension()) - ->setName($lbRouteExtensionName) - ->setForwardingRules($lbRouteExtensionForwardingRules) - ->setExtensionChains($lbRouteExtensionExtensionChains) - ->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $depServiceClient->createLbRouteExtension( - $formattedParent, - $lbRouteExtensionId, - $lbRouteExtension - ); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LbRouteExtension $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 = DepServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $lbRouteExtensionId = '[LB_ROUTE_EXTENSION_ID]'; - $lbRouteExtensionName = '[NAME]'; - $lbRouteExtensionForwardingRulesElement = '[FORWARDING_RULES]'; - $lbRouteExtensionExtensionChainsName = '[NAME]'; - $lbRouteExtensionExtensionChainsMatchConditionCelExpression = '[CEL_EXPRESSION]'; - $lbRouteExtensionExtensionChainsExtensionsName = '[NAME]'; - $lbRouteExtensionExtensionChainsExtensionsService = '[SERVICE]'; - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - - create_lb_route_extension_sample( - $formattedParent, - $lbRouteExtensionId, - $lbRouteExtensionName, - $lbRouteExtensionForwardingRulesElement, - $lbRouteExtensionExtensionChainsName, - $lbRouteExtensionExtensionChainsMatchConditionCelExpression, - $lbRouteExtensionExtensionChainsExtensionsName, - $lbRouteExtensionExtensionChainsExtensionsService, - $lbRouteExtensionLoadBalancingScheme - ); -} -// [END networkservices_v1_generated_DepService_CreateLbRouteExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_traffic_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_traffic_extension.php deleted file mode 100644 index 2e9a47c1e5ba..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/create_lb_traffic_extension.php +++ /dev/null @@ -1,176 +0,0 @@ -setCelExpression($lbTrafficExtensionExtensionChainsMatchConditionCelExpression); - $extension = (new Extension()) - ->setName($lbTrafficExtensionExtensionChainsExtensionsName) - ->setService($lbTrafficExtensionExtensionChainsExtensionsService); - $lbTrafficExtensionExtensionChainsExtensions = [$extension,]; - $extensionChain = (new ExtensionChain()) - ->setName($lbTrafficExtensionExtensionChainsName) - ->setMatchCondition($lbTrafficExtensionExtensionChainsMatchCondition) - ->setExtensions($lbTrafficExtensionExtensionChainsExtensions); - $lbTrafficExtensionExtensionChains = [$extensionChain,]; - $lbTrafficExtension = (new LbTrafficExtension()) - ->setName($lbTrafficExtensionName) - ->setForwardingRules($lbTrafficExtensionForwardingRules) - ->setExtensionChains($lbTrafficExtensionExtensionChains) - ->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $depServiceClient->createLbTrafficExtension( - $formattedParent, - $lbTrafficExtensionId, - $lbTrafficExtension - ); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LbTrafficExtension $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 = DepServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $lbTrafficExtensionId = '[LB_TRAFFIC_EXTENSION_ID]'; - $lbTrafficExtensionName = '[NAME]'; - $lbTrafficExtensionForwardingRulesElement = '[FORWARDING_RULES]'; - $lbTrafficExtensionExtensionChainsName = '[NAME]'; - $lbTrafficExtensionExtensionChainsMatchConditionCelExpression = '[CEL_EXPRESSION]'; - $lbTrafficExtensionExtensionChainsExtensionsName = '[NAME]'; - $lbTrafficExtensionExtensionChainsExtensionsService = '[SERVICE]'; - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - - create_lb_traffic_extension_sample( - $formattedParent, - $lbTrafficExtensionId, - $lbTrafficExtensionName, - $lbTrafficExtensionForwardingRulesElement, - $lbTrafficExtensionExtensionChainsName, - $lbTrafficExtensionExtensionChainsMatchConditionCelExpression, - $lbTrafficExtensionExtensionChainsExtensionsName, - $lbTrafficExtensionExtensionChainsExtensionsService, - $lbTrafficExtensionLoadBalancingScheme - ); -} -// [END networkservices_v1_generated_DepService_CreateLbTrafficExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_route_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_route_extension.php deleted file mode 100644 index 2df81768f9af..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_route_extension.php +++ /dev/null @@ -1,81 +0,0 @@ -deleteLbRouteExtension($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = DepServiceClient::lbRouteExtensionName( - '[PROJECT]', - '[LOCATION]', - '[LB_ROUTE_EXTENSION]' - ); - - delete_lb_route_extension_sample($formattedName); -} -// [END networkservices_v1_generated_DepService_DeleteLbRouteExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_traffic_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_traffic_extension.php deleted file mode 100644 index fc42b3518345..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/delete_lb_traffic_extension.php +++ /dev/null @@ -1,81 +0,0 @@ -deleteLbTrafficExtension($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = DepServiceClient::lbTrafficExtensionName( - '[PROJECT]', - '[LOCATION]', - '[LB_TRAFFIC_EXTENSION]' - ); - - delete_lb_traffic_extension_sample($formattedName); -} -// [END networkservices_v1_generated_DepService_DeleteLbTrafficExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_iam_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_iam_policy.php deleted file mode 100644 index 832b15c7c359..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_iam_policy.php +++ /dev/null @@ -1,67 +0,0 @@ -getIamPolicy($resource); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - get_iam_policy_sample($resource); -} -// [END networkservices_v1_generated_DepService_GetIamPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_route_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_route_extension.php deleted file mode 100644 index ef31fa9b961f..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_route_extension.php +++ /dev/null @@ -1,72 +0,0 @@ -getLbRouteExtension($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = DepServiceClient::lbRouteExtensionName( - '[PROJECT]', - '[LOCATION]', - '[LB_ROUTE_EXTENSION]' - ); - - get_lb_route_extension_sample($formattedName); -} -// [END networkservices_v1_generated_DepService_GetLbRouteExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_traffic_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_traffic_extension.php deleted file mode 100644 index cb36945c2eba..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_lb_traffic_extension.php +++ /dev/null @@ -1,72 +0,0 @@ -getLbTrafficExtension($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = DepServiceClient::lbTrafficExtensionName( - '[PROJECT]', - '[LOCATION]', - '[LB_TRAFFIC_EXTENSION]' - ); - - get_lb_traffic_extension_sample($formattedName); -} -// [END networkservices_v1_generated_DepService_GetLbTrafficExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_location.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_location.php deleted file mode 100644 index bbff9dad5472..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/get_location.php +++ /dev/null @@ -1,53 +0,0 @@ -getLocation(); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END networkservices_v1_generated_DepService_GetLocation_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_route_extensions.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_route_extensions.php deleted file mode 100644 index c137b56d4588..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_route_extensions.php +++ /dev/null @@ -1,73 +0,0 @@ -listLbRouteExtensions($formattedParent); - - /** @var LbRouteExtension $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 = DepServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_lb_route_extensions_sample($formattedParent); -} -// [END networkservices_v1_generated_DepService_ListLbRouteExtensions_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_traffic_extensions.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_traffic_extensions.php deleted file mode 100644 index 634a564a0e49..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_lb_traffic_extensions.php +++ /dev/null @@ -1,73 +0,0 @@ -listLbTrafficExtensions($formattedParent); - - /** @var LbTrafficExtension $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 = DepServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_lb_traffic_extensions_sample($formattedParent); -} -// [END networkservices_v1_generated_DepService_ListLbTrafficExtensions_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_locations.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_locations.php deleted file mode 100644 index 4801d3cb82a2..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/list_locations.php +++ /dev/null @@ -1,58 +0,0 @@ -listLocations(); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END networkservices_v1_generated_DepService_ListLocations_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/set_iam_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/set_iam_policy.php deleted file mode 100644 index c38ed7f06c3c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setIamPolicy($resource, $policy); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - set_iam_policy_sample($resource); -} -// [END networkservices_v1_generated_DepService_SetIamPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/test_iam_permissions.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/test_iam_permissions.php deleted file mode 100644 index 6274d58218e6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,80 +0,0 @@ -testIamPermissions($resource, $permissions); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - $permissionsElement = '[PERMISSIONS]'; - - test_iam_permissions_sample($resource, $permissionsElement); -} -// [END networkservices_v1_generated_DepService_TestIamPermissions_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_route_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_route_extension.php deleted file mode 100644 index 6a6c037a79c6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_route_extension.php +++ /dev/null @@ -1,160 +0,0 @@ -setCelExpression($lbRouteExtensionExtensionChainsMatchConditionCelExpression); - $extension = (new Extension()) - ->setName($lbRouteExtensionExtensionChainsExtensionsName) - ->setService($lbRouteExtensionExtensionChainsExtensionsService); - $lbRouteExtensionExtensionChainsExtensions = [$extension,]; - $extensionChain = (new ExtensionChain()) - ->setName($lbRouteExtensionExtensionChainsName) - ->setMatchCondition($lbRouteExtensionExtensionChainsMatchCondition) - ->setExtensions($lbRouteExtensionExtensionChainsExtensions); - $lbRouteExtensionExtensionChains = [$extensionChain,]; - $lbRouteExtension = (new LbRouteExtension()) - ->setName($lbRouteExtensionName) - ->setForwardingRules($lbRouteExtensionForwardingRules) - ->setExtensionChains($lbRouteExtensionExtensionChains) - ->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $depServiceClient->updateLbRouteExtension($lbRouteExtension); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LbRouteExtension $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 -{ - $lbRouteExtensionName = '[NAME]'; - $lbRouteExtensionForwardingRulesElement = '[FORWARDING_RULES]'; - $lbRouteExtensionExtensionChainsName = '[NAME]'; - $lbRouteExtensionExtensionChainsMatchConditionCelExpression = '[CEL_EXPRESSION]'; - $lbRouteExtensionExtensionChainsExtensionsName = '[NAME]'; - $lbRouteExtensionExtensionChainsExtensionsService = '[SERVICE]'; - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - - update_lb_route_extension_sample( - $lbRouteExtensionName, - $lbRouteExtensionForwardingRulesElement, - $lbRouteExtensionExtensionChainsName, - $lbRouteExtensionExtensionChainsMatchConditionCelExpression, - $lbRouteExtensionExtensionChainsExtensionsName, - $lbRouteExtensionExtensionChainsExtensionsService, - $lbRouteExtensionLoadBalancingScheme - ); -} -// [END networkservices_v1_generated_DepService_UpdateLbRouteExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_traffic_extension.php b/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_traffic_extension.php deleted file mode 100644 index 3480f1d17892..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/DepServiceClient/update_lb_traffic_extension.php +++ /dev/null @@ -1,160 +0,0 @@ -setCelExpression($lbTrafficExtensionExtensionChainsMatchConditionCelExpression); - $extension = (new Extension()) - ->setName($lbTrafficExtensionExtensionChainsExtensionsName) - ->setService($lbTrafficExtensionExtensionChainsExtensionsService); - $lbTrafficExtensionExtensionChainsExtensions = [$extension,]; - $extensionChain = (new ExtensionChain()) - ->setName($lbTrafficExtensionExtensionChainsName) - ->setMatchCondition($lbTrafficExtensionExtensionChainsMatchCondition) - ->setExtensions($lbTrafficExtensionExtensionChainsExtensions); - $lbTrafficExtensionExtensionChains = [$extensionChain,]; - $lbTrafficExtension = (new LbTrafficExtension()) - ->setName($lbTrafficExtensionName) - ->setForwardingRules($lbTrafficExtensionForwardingRules) - ->setExtensionChains($lbTrafficExtensionExtensionChains) - ->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $depServiceClient->updateLbTrafficExtension($lbTrafficExtension); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LbTrafficExtension $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 -{ - $lbTrafficExtensionName = '[NAME]'; - $lbTrafficExtensionForwardingRulesElement = '[FORWARDING_RULES]'; - $lbTrafficExtensionExtensionChainsName = '[NAME]'; - $lbTrafficExtensionExtensionChainsMatchConditionCelExpression = '[CEL_EXPRESSION]'; - $lbTrafficExtensionExtensionChainsExtensionsName = '[NAME]'; - $lbTrafficExtensionExtensionChainsExtensionsService = '[SERVICE]'; - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - - update_lb_traffic_extension_sample( - $lbTrafficExtensionName, - $lbTrafficExtensionForwardingRulesElement, - $lbTrafficExtensionExtensionChainsName, - $lbTrafficExtensionExtensionChainsMatchConditionCelExpression, - $lbTrafficExtensionExtensionChainsExtensionsName, - $lbTrafficExtensionExtensionChainsExtensionsService, - $lbTrafficExtensionLoadBalancingScheme - ); -} -// [END networkservices_v1_generated_DepService_UpdateLbTrafficExtension_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_endpoint_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_endpoint_policy.php deleted file mode 100644 index 2aa8f48da9de..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_endpoint_policy.php +++ /dev/null @@ -1,110 +0,0 @@ -setName($endpointPolicyName) - ->setType($endpointPolicyType) - ->setEndpointMatcher($endpointPolicyEndpointMatcher); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createEndpointPolicy( - $formattedParent, - $endpointPolicyId, - $endpointPolicy - ); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var EndpointPolicy $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $endpointPolicyId = '[ENDPOINT_POLICY_ID]'; - $endpointPolicyName = '[NAME]'; - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - - create_endpoint_policy_sample( - $formattedParent, - $endpointPolicyId, - $endpointPolicyName, - $endpointPolicyType - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateEndpointPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_gateway.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_gateway.php deleted file mode 100644 index 126f873f0749..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_gateway.php +++ /dev/null @@ -1,115 +0,0 @@ -`. - * @param int $gatewayPortsElement One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * @param string $gatewayScope Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - */ -function create_gateway_sample( - string $formattedParent, - string $gatewayId, - string $gatewayName, - int $gatewayPortsElement, - string $gatewayScope -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $gatewayPorts = [$gatewayPortsElement,]; - $gateway = (new Gateway()) - ->setName($gatewayName) - ->setPorts($gatewayPorts) - ->setScope($gatewayScope); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createGateway($formattedParent, $gatewayId, $gateway); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Gateway $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $gatewayId = '[GATEWAY_ID]'; - $gatewayName = '[NAME]'; - $gatewayPortsElement = 0; - $gatewayScope = '[SCOPE]'; - - create_gateway_sample( - $formattedParent, - $gatewayId, - $gatewayName, - $gatewayPortsElement, - $gatewayScope - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateGateway_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_grpc_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_grpc_route.php deleted file mode 100644 index dc9aa621c9bd..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_grpc_route.php +++ /dev/null @@ -1,138 +0,0 @@ -` - * @param string $grpcRouteHostnamesElement Service hostnames with an optional port for which this route - * describes traffic. - * - * Format: [:] - * - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - */ -function create_grpc_route_sample( - string $formattedParent, - string $grpcRouteId, - string $grpcRouteName, - string $grpcRouteHostnamesElement -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $grpcRouteHostnames = [$grpcRouteHostnamesElement,]; - $grpcRouteRulesAction = new RouteAction(); - $routeRule = (new RouteRule()) - ->setAction($grpcRouteRulesAction); - $grpcRouteRules = [$routeRule,]; - $grpcRoute = (new GrpcRoute()) - ->setName($grpcRouteName) - ->setHostnames($grpcRouteHostnames) - ->setRules($grpcRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createGrpcRoute($formattedParent, $grpcRouteId, $grpcRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var GrpcRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $grpcRouteId = '[GRPC_ROUTE_ID]'; - $grpcRouteName = '[NAME]'; - $grpcRouteHostnamesElement = '[HOSTNAMES]'; - - create_grpc_route_sample( - $formattedParent, - $grpcRouteId, - $grpcRouteName, - $grpcRouteHostnamesElement - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateGrpcRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_http_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_http_route.php deleted file mode 100644 index 5fd253d5b741..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_http_route.php +++ /dev/null @@ -1,127 +0,0 @@ -`. - * @param string $httpRouteHostnamesElement Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - */ -function create_http_route_sample( - string $formattedParent, - string $httpRouteId, - string $httpRouteName, - string $httpRouteHostnamesElement -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $httpRouteHostnames = [$httpRouteHostnamesElement,]; - $httpRouteRules = [new RouteRule()]; - $httpRoute = (new HttpRoute()) - ->setName($httpRouteName) - ->setHostnames($httpRouteHostnames) - ->setRules($httpRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createHttpRoute($formattedParent, $httpRouteId, $httpRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var HttpRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $httpRouteId = '[HTTP_ROUTE_ID]'; - $httpRouteName = '[NAME]'; - $httpRouteHostnamesElement = '[HOSTNAMES]'; - - create_http_route_sample( - $formattedParent, - $httpRouteId, - $httpRouteName, - $httpRouteHostnamesElement - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateHttpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_mesh.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_mesh.php deleted file mode 100644 index 9f1b6b794526..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_mesh.php +++ /dev/null @@ -1,88 +0,0 @@ -`. - */ -function create_mesh_sample(string $formattedParent, string $meshId, string $meshName): void -{ - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $mesh = (new Mesh()) - ->setName($meshName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createMesh($formattedParent, $meshId, $mesh); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Mesh $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $meshId = '[MESH_ID]'; - $meshName = '[NAME]'; - - create_mesh_sample($formattedParent, $meshId, $meshName); -} -// [END networkservices_v1_generated_NetworkServices_CreateMesh_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_service_binding.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_service_binding.php deleted file mode 100644 index 406278babd24..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_service_binding.php +++ /dev/null @@ -1,105 +0,0 @@ -setName($serviceBindingName) - ->setService($serviceBindingService); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createServiceBinding( - $formattedParent, - $serviceBindingId, - $serviceBinding - ); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ServiceBinding $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $serviceBindingId = '[SERVICE_BINDING_ID]'; - $serviceBindingName = '[NAME]'; - $serviceBindingService = '[SERVICE]'; - - create_service_binding_sample( - $formattedParent, - $serviceBindingId, - $serviceBindingName, - $serviceBindingService - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateServiceBinding_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tcp_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tcp_route.php deleted file mode 100644 index c9fa3555fcde..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tcp_route.php +++ /dev/null @@ -1,98 +0,0 @@ -`. - */ -function create_tcp_route_sample( - string $formattedParent, - string $tcpRouteId, - string $tcpRouteName -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $tcpRouteRulesAction = new RouteAction(); - $routeRule = (new RouteRule()) - ->setAction($tcpRouteRulesAction); - $tcpRouteRules = [$routeRule,]; - $tcpRoute = (new TcpRoute()) - ->setName($tcpRouteName) - ->setRules($tcpRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createTcpRoute($formattedParent, $tcpRouteId, $tcpRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var TcpRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $tcpRouteId = '[TCP_ROUTE_ID]'; - $tcpRouteName = '[NAME]'; - - create_tcp_route_sample($formattedParent, $tcpRouteId, $tcpRouteName); -} -// [END networkservices_v1_generated_NetworkServices_CreateTcpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tls_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tls_route.php deleted file mode 100644 index bb6ebbf6a796..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/create_tls_route.php +++ /dev/null @@ -1,119 +0,0 @@ -`. - * @param string $formattedTlsRouteRulesActionDestinationsServiceName The URL of a BackendService to route traffic to. Please see - * {@see NetworkServicesClient::backendServiceName()} for help formatting this field. - */ -function create_tls_route_sample( - string $formattedParent, - string $tlsRouteId, - string $tlsRouteName, - string $formattedTlsRouteRulesActionDestinationsServiceName -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $tlsRouteRulesMatches = [new RouteMatch()]; - $routeDestination = (new RouteDestination()) - ->setServiceName($formattedTlsRouteRulesActionDestinationsServiceName); - $tlsRouteRulesActionDestinations = [$routeDestination,]; - $tlsRouteRulesAction = (new RouteAction()) - ->setDestinations($tlsRouteRulesActionDestinations); - $routeRule = (new RouteRule()) - ->setMatches($tlsRouteRulesMatches) - ->setAction($tlsRouteRulesAction); - $tlsRouteRules = [$routeRule,]; - $tlsRoute = (new TlsRoute()) - ->setName($tlsRouteName) - ->setRules($tlsRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->createTlsRoute($formattedParent, $tlsRouteId, $tlsRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var TlsRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - $tlsRouteId = '[TLS_ROUTE_ID]'; - $tlsRouteName = '[NAME]'; - $formattedTlsRouteRulesActionDestinationsServiceName = NetworkServicesClient::backendServiceName( - '[PROJECT]', - '[LOCATION]', - '[BACKEND_SERVICE]' - ); - - create_tls_route_sample( - $formattedParent, - $tlsRouteId, - $tlsRouteName, - $formattedTlsRouteRulesActionDestinationsServiceName - ); -} -// [END networkservices_v1_generated_NetworkServices_CreateTlsRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_endpoint_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_endpoint_policy.php deleted file mode 100644 index 75a1d8ec33ca..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_endpoint_policy.php +++ /dev/null @@ -1,80 +0,0 @@ -deleteEndpointPolicy($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::endpointPolicyName( - '[PROJECT]', - '[LOCATION]', - '[ENDPOINT_POLICY]' - ); - - delete_endpoint_policy_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteEndpointPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_gateway.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_gateway.php deleted file mode 100644 index 004b9523e533..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_gateway.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteGateway($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - - delete_gateway_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteGateway_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_grpc_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_grpc_route.php deleted file mode 100644 index 7c932c859d5e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_grpc_route.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteGrpcRoute($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - - delete_grpc_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteGrpcRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_http_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_http_route.php deleted file mode 100644 index c634d8c2e8d2..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_http_route.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteHttpRoute($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - - delete_http_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteHttpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_mesh.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_mesh.php deleted file mode 100644 index b633a303aff2..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_mesh.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteMesh($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - - delete_mesh_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteMesh_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_service_binding.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_service_binding.php deleted file mode 100644 index e6cfea124f1c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_service_binding.php +++ /dev/null @@ -1,80 +0,0 @@ -deleteServiceBinding($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::serviceBindingName( - '[PROJECT]', - '[LOCATION]', - '[SERVICE_BINDING]' - ); - - delete_service_binding_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteServiceBinding_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tcp_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tcp_route.php deleted file mode 100644 index cc696c7296e8..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tcp_route.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteTcpRoute($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - - delete_tcp_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteTcpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tls_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tls_route.php deleted file mode 100644 index f4ffb3b17d07..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/delete_tls_route.php +++ /dev/null @@ -1,76 +0,0 @@ -deleteTlsRoute($formattedName); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - printf('Operation completed successfully.' . PHP_EOL); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - - delete_tls_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_DeleteTlsRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_endpoint_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_endpoint_policy.php deleted file mode 100644 index ecbec1690753..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_endpoint_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -getEndpointPolicy($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::endpointPolicyName( - '[PROJECT]', - '[LOCATION]', - '[ENDPOINT_POLICY]' - ); - - get_endpoint_policy_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetEndpointPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_gateway.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_gateway.php deleted file mode 100644 index ca4a9a0f1d35..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_gateway.php +++ /dev/null @@ -1,67 +0,0 @@ -getGateway($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - - get_gateway_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetGateway_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_grpc_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_grpc_route.php deleted file mode 100644 index 70376169c80d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_grpc_route.php +++ /dev/null @@ -1,67 +0,0 @@ -getGrpcRoute($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - - get_grpc_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetGrpcRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_http_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_http_route.php deleted file mode 100644 index 30236bfaa045..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_http_route.php +++ /dev/null @@ -1,67 +0,0 @@ -getHttpRoute($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - - get_http_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetHttpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_iam_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_iam_policy.php deleted file mode 100644 index 940b4c0f3e6e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_iam_policy.php +++ /dev/null @@ -1,67 +0,0 @@ -getIamPolicy($resource); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - get_iam_policy_sample($resource); -} -// [END networkservices_v1_generated_NetworkServices_GetIamPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_location.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_location.php deleted file mode 100644 index 67e709f726c7..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_location.php +++ /dev/null @@ -1,53 +0,0 @@ -getLocation(); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END networkservices_v1_generated_NetworkServices_GetLocation_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_mesh.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_mesh.php deleted file mode 100644 index f41d60ac2c17..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_mesh.php +++ /dev/null @@ -1,67 +0,0 @@ -getMesh($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - - get_mesh_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetMesh_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_service_binding.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_service_binding.php deleted file mode 100644 index 0c579cf3ba9c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_service_binding.php +++ /dev/null @@ -1,71 +0,0 @@ -getServiceBinding($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::serviceBindingName( - '[PROJECT]', - '[LOCATION]', - '[SERVICE_BINDING]' - ); - - get_service_binding_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetServiceBinding_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tcp_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tcp_route.php deleted file mode 100644 index e552e73f0cfc..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tcp_route.php +++ /dev/null @@ -1,67 +0,0 @@ -getTcpRoute($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - - get_tcp_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetTcpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tls_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tls_route.php deleted file mode 100644 index c7b20170cc5c..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/get_tls_route.php +++ /dev/null @@ -1,67 +0,0 @@ -getTlsRoute($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = NetworkServicesClient::tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - - get_tls_route_sample($formattedName); -} -// [END networkservices_v1_generated_NetworkServices_GetTlsRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_endpoint_policies.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_endpoint_policies.php deleted file mode 100644 index 8147e92ba408..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_endpoint_policies.php +++ /dev/null @@ -1,72 +0,0 @@ -listEndpointPolicies($formattedParent); - - /** @var EndpointPolicy $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_endpoint_policies_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListEndpointPolicies_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_gateways.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_gateways.php deleted file mode 100644 index 04442a8d900b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_gateways.php +++ /dev/null @@ -1,72 +0,0 @@ -listGateways($formattedParent); - - /** @var Gateway $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_gateways_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListGateways_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_grpc_routes.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_grpc_routes.php deleted file mode 100644 index e1801bbe87a9..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_grpc_routes.php +++ /dev/null @@ -1,72 +0,0 @@ -listGrpcRoutes($formattedParent); - - /** @var GrpcRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_grpc_routes_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListGrpcRoutes_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_http_routes.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_http_routes.php deleted file mode 100644 index a127eacc570b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_http_routes.php +++ /dev/null @@ -1,72 +0,0 @@ -listHttpRoutes($formattedParent); - - /** @var HttpRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_http_routes_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListHttpRoutes_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_locations.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_locations.php deleted file mode 100644 index 269d1269bf55..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_locations.php +++ /dev/null @@ -1,58 +0,0 @@ -listLocations(); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END networkservices_v1_generated_NetworkServices_ListLocations_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_meshes.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_meshes.php deleted file mode 100644 index 35dfeecd85b3..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_meshes.php +++ /dev/null @@ -1,72 +0,0 @@ -listMeshes($formattedParent); - - /** @var Mesh $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_meshes_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListMeshes_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_service_bindings.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_service_bindings.php deleted file mode 100644 index 28e98b073bee..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_service_bindings.php +++ /dev/null @@ -1,72 +0,0 @@ -listServiceBindings($formattedParent); - - /** @var ServiceBinding $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_service_bindings_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListServiceBindings_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tcp_routes.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tcp_routes.php deleted file mode 100644 index fdf7e2714912..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tcp_routes.php +++ /dev/null @@ -1,72 +0,0 @@ -listTcpRoutes($formattedParent); - - /** @var TcpRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_tcp_routes_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListTcpRoutes_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tls_routes.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tls_routes.php deleted file mode 100644 index 209d60ded156..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/list_tls_routes.php +++ /dev/null @@ -1,72 +0,0 @@ -listTlsRoutes($formattedParent); - - /** @var TlsRoute $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 = NetworkServicesClient::locationName('[PROJECT]', '[LOCATION]'); - - list_tls_routes_sample($formattedParent); -} -// [END networkservices_v1_generated_NetworkServices_ListTlsRoutes_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/set_iam_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/set_iam_policy.php deleted file mode 100644 index 9650d9511d36..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setIamPolicy($resource, $policy); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - set_iam_policy_sample($resource); -} -// [END networkservices_v1_generated_NetworkServices_SetIamPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/test_iam_permissions.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/test_iam_permissions.php deleted file mode 100644 index d5cbc0435ed6..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/test_iam_permissions.php +++ /dev/null @@ -1,80 +0,0 @@ -testIamPermissions($resource, $permissions); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - $permissionsElement = '[PERMISSIONS]'; - - test_iam_permissions_sample($resource, $permissionsElement); -} -// [END networkservices_v1_generated_NetworkServices_TestIamPermissions_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_endpoint_policy.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_endpoint_policy.php deleted file mode 100644 index c8af2b89d13d..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_endpoint_policy.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($endpointPolicyName) - ->setType($endpointPolicyType) - ->setEndpointMatcher($endpointPolicyEndpointMatcher); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateEndpointPolicy($endpointPolicy); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var EndpointPolicy $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 -{ - $endpointPolicyName = '[NAME]'; - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - - update_endpoint_policy_sample($endpointPolicyName, $endpointPolicyType); -} -// [END networkservices_v1_generated_NetworkServices_UpdateEndpointPolicy_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_gateway.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_gateway.php deleted file mode 100644 index a14c29803888..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_gateway.php +++ /dev/null @@ -1,101 +0,0 @@ -`. - * @param int $gatewayPortsElement One or more ports that the Gateway must receive traffic on. The - * proxy binds to the ports specified. Gateway listen on 0.0.0.0 on the ports - * specified below. - * @param string $gatewayScope Immutable. Scope determines how configuration across multiple - * Gateway instances are merged. The configuration for multiple Gateway - * instances with the same scope will be merged as presented as a single - * coniguration to the proxy/load balancer. - * - * Max length 64 characters. - * Scope should start with a letter and can only have letters, numbers, - * hyphens. - */ -function update_gateway_sample( - string $gatewayName, - int $gatewayPortsElement, - string $gatewayScope -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $gatewayPorts = [$gatewayPortsElement,]; - $gateway = (new Gateway()) - ->setName($gatewayName) - ->setPorts($gatewayPorts) - ->setScope($gatewayScope); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateGateway($gateway); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Gateway $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 -{ - $gatewayName = '[NAME]'; - $gatewayPortsElement = 0; - $gatewayScope = '[SCOPE]'; - - update_gateway_sample($gatewayName, $gatewayPortsElement, $gatewayScope); -} -// [END networkservices_v1_generated_NetworkServices_UpdateGateway_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_grpc_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_grpc_route.php deleted file mode 100644 index 7f46e6d62d3e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_grpc_route.php +++ /dev/null @@ -1,123 +0,0 @@ -` - * @param string $grpcRouteHostnamesElement Service hostnames with an optional port for which this route - * describes traffic. - * - * Format: [:] - * - * Hostname is the fully qualified domain name of a network host. This matches - * the RFC 1123 definition of a hostname with 2 notable exceptions: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * - * The routes associated with a Mesh or Gateway must have unique hostnames. If - * you attempt to attach multiple routes with conflicting hostnames, the - * configuration will be rejected. - * - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same route, it is - * not possible to associate two routes both with `*.bar.com` or both with - * `bar.com`. - * - * If a port is specified, then gRPC clients must use the channel URI with the - * port to match this rule (i.e. "xds:///service:123"), otherwise they must - * supply the URI without a port (i.e. "xds:///service"). - */ -function update_grpc_route_sample(string $grpcRouteName, string $grpcRouteHostnamesElement): void -{ - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $grpcRouteHostnames = [$grpcRouteHostnamesElement,]; - $grpcRouteRulesAction = new RouteAction(); - $routeRule = (new RouteRule()) - ->setAction($grpcRouteRulesAction); - $grpcRouteRules = [$routeRule,]; - $grpcRoute = (new GrpcRoute()) - ->setName($grpcRouteName) - ->setHostnames($grpcRouteHostnames) - ->setRules($grpcRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateGrpcRoute($grpcRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var GrpcRoute $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 -{ - $grpcRouteName = '[NAME]'; - $grpcRouteHostnamesElement = '[HOSTNAMES]'; - - update_grpc_route_sample($grpcRouteName, $grpcRouteHostnamesElement); -} -// [END networkservices_v1_generated_NetworkServices_UpdateGrpcRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_http_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_http_route.php deleted file mode 100644 index 3608abfb0134..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_http_route.php +++ /dev/null @@ -1,112 +0,0 @@ -`. - * @param string $httpRouteHostnamesElement Hostnames define a set of hosts that should match against the - * HTTP host header to select a HttpRoute to process the request. Hostname is - * the fully qualified domain name of a network host, as defined by RFC 1123 - * with the exception that: - * - IPs are not allowed. - * - A hostname may be prefixed with a wildcard label (`*.`). The wildcard - * label must appear by itself as the first label. - * - * Hostname can be "precise" which is a domain name without the terminating - * dot of a network host (e.g. `foo.example.com`) or "wildcard", which is a - * domain name prefixed with a single wildcard label (e.g. `*.example.com`). - * - * Note that as per RFC1035 and RFC1123, a label must consist of lower case - * alphanumeric characters or '-', and must start and end with an alphanumeric - * character. No other punctuation is allowed. - * - * The routes associated with a Mesh or Gateways must have unique hostnames. - * If you attempt to attach multiple routes with conflicting hostnames, - * the configuration will be rejected. - * - * For example, while it is acceptable for routes for the hostnames - * `*.foo.bar.com` and `*.bar.com` to be associated with the same Mesh (or - * Gateways under the same scope), it is not possible to associate two routes - * both with `*.bar.com` or both with `bar.com`. - */ -function update_http_route_sample(string $httpRouteName, string $httpRouteHostnamesElement): void -{ - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $httpRouteHostnames = [$httpRouteHostnamesElement,]; - $httpRouteRules = [new RouteRule()]; - $httpRoute = (new HttpRoute()) - ->setName($httpRouteName) - ->setHostnames($httpRouteHostnames) - ->setRules($httpRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateHttpRoute($httpRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var HttpRoute $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 -{ - $httpRouteName = '[NAME]'; - $httpRouteHostnamesElement = '[HOSTNAMES]'; - - update_http_route_sample($httpRouteName, $httpRouteHostnamesElement); -} -// [END networkservices_v1_generated_NetworkServices_UpdateHttpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_mesh.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_mesh.php deleted file mode 100644 index faea526d27ad..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_mesh.php +++ /dev/null @@ -1,82 +0,0 @@ -`. - */ -function update_mesh_sample(string $meshName): void -{ - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $mesh = (new Mesh()) - ->setName($meshName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateMesh($mesh); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Mesh $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 -{ - $meshName = '[NAME]'; - - update_mesh_sample($meshName); -} -// [END networkservices_v1_generated_NetworkServices_UpdateMesh_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tcp_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tcp_route.php deleted file mode 100644 index a68a27818f9e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tcp_route.php +++ /dev/null @@ -1,89 +0,0 @@ -`. - */ -function update_tcp_route_sample(string $tcpRouteName): void -{ - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $tcpRouteRulesAction = new RouteAction(); - $routeRule = (new RouteRule()) - ->setAction($tcpRouteRulesAction); - $tcpRouteRules = [$routeRule,]; - $tcpRoute = (new TcpRoute()) - ->setName($tcpRouteName) - ->setRules($tcpRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateTcpRoute($tcpRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var TcpRoute $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 -{ - $tcpRouteName = '[NAME]'; - - update_tcp_route_sample($tcpRouteName); -} -// [END networkservices_v1_generated_NetworkServices_UpdateTcpRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tls_route.php b/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tls_route.php deleted file mode 100644 index 563f4a423ea7..000000000000 --- a/owl-bot-staging/NetworkServices/v1/samples/V1/NetworkServicesClient/update_tls_route.php +++ /dev/null @@ -1,106 +0,0 @@ -`. - * @param string $formattedTlsRouteRulesActionDestinationsServiceName The URL of a BackendService to route traffic to. Please see - * {@see NetworkServicesClient::backendServiceName()} for help formatting this field. - */ -function update_tls_route_sample( - string $tlsRouteName, - string $formattedTlsRouteRulesActionDestinationsServiceName -): void { - // Create a client. - $networkServicesClient = new NetworkServicesClient(); - - // Prepare any non-scalar elements to be passed along with the request. - $tlsRouteRulesMatches = [new RouteMatch()]; - $routeDestination = (new RouteDestination()) - ->setServiceName($formattedTlsRouteRulesActionDestinationsServiceName); - $tlsRouteRulesActionDestinations = [$routeDestination,]; - $tlsRouteRulesAction = (new RouteAction()) - ->setDestinations($tlsRouteRulesActionDestinations); - $routeRule = (new RouteRule()) - ->setMatches($tlsRouteRulesMatches) - ->setAction($tlsRouteRulesAction); - $tlsRouteRules = [$routeRule,]; - $tlsRoute = (new TlsRoute()) - ->setName($tlsRouteName) - ->setRules($tlsRouteRules); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $networkServicesClient->updateTlsRoute($tlsRoute); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var TlsRoute $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 -{ - $tlsRouteName = '[NAME]'; - $formattedTlsRouteRulesActionDestinationsServiceName = NetworkServicesClient::backendServiceName( - '[PROJECT]', - '[LOCATION]', - '[BACKEND_SERVICE]' - ); - - update_tls_route_sample($tlsRouteName, $formattedTlsRouteRulesActionDestinationsServiceName); -} -// [END networkservices_v1_generated_NetworkServices_UpdateTlsRoute_sync] diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/DepServiceClient.php b/owl-bot-staging/NetworkServices/v1/src/V1/DepServiceClient.php deleted file mode 100644 index f0542ec40f33..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/DepServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $lbRouteExtensionId = 'lb_route_extension_id'; - * $lbRouteExtension = new LbRouteExtension(); - * $operationResponse = $depServiceClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'createLbRouteExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * Many parameters require resource names to be formatted in a particular way. To - * assist with these names, this class includes a format method for each type of - * name, and additionally a parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @deprecated This class will be removed in the next major version update. - */ -class DepServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.networkservices.v1.DepService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'networkservices.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'networkservices.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $lbRouteExtensionNameTemplate; - - private static $lbTrafficExtensionNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/dep_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/dep_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/dep_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/dep_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getLbRouteExtensionNameTemplate() - { - if (self::$lbRouteExtensionNameTemplate == null) { - self::$lbRouteExtensionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}'); - } - - return self::$lbRouteExtensionNameTemplate; - } - - private static function getLbTrafficExtensionNameTemplate() - { - if (self::$lbTrafficExtensionNameTemplate == null) { - self::$lbTrafficExtensionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}'); - } - - return self::$lbTrafficExtensionNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'lbRouteExtension' => self::getLbRouteExtensionNameTemplate(), - 'lbTrafficExtension' => self::getLbTrafficExtensionNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * lb_route_extension resource. - * - * @param string $project - * @param string $location - * @param string $lbRouteExtension - * - * @return string The formatted lb_route_extension resource. - */ - public static function lbRouteExtensionName($project, $location, $lbRouteExtension) - { - return self::getLbRouteExtensionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'lb_route_extension' => $lbRouteExtension, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * lb_traffic_extension resource. - * - * @param string $project - * @param string $location - * @param string $lbTrafficExtension - * - * @return string The formatted lb_traffic_extension resource. - */ - public static function lbTrafficExtensionName($project, $location, $lbTrafficExtension) - { - return self::getLbTrafficExtensionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'lb_traffic_extension' => $lbTrafficExtension, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - lbRouteExtension: projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension} - * - lbTrafficExtension: projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension} - * - location: projects/{project}/locations/{location} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'networkservices.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new `LbRouteExtension` resource in a given project and location. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedParent = $depServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $lbRouteExtensionId = 'lb_route_extension_id'; - * $lbRouteExtension = new LbRouteExtension(); - * $operationResponse = $depServiceClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'createLbRouteExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the `LbRouteExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * @param string $lbRouteExtensionId Required. User-provided ID of the `LbRouteExtension` resource to be - * created. - * @param LbRouteExtension $lbRouteExtension Required. `LbRouteExtension` resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createLbRouteExtension($parent, $lbRouteExtensionId, $lbRouteExtension, array $optionalArgs = []) - { - $request = new CreateLbRouteExtensionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setLbRouteExtensionId($lbRouteExtensionId); - $request->setLbRouteExtension($lbRouteExtension); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateLbRouteExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new `LbTrafficExtension` resource in a given project and - * location. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedParent = $depServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $lbTrafficExtensionId = 'lb_traffic_extension_id'; - * $lbTrafficExtension = new LbTrafficExtension(); - * $operationResponse = $depServiceClient->createLbTrafficExtension($formattedParent, $lbTrafficExtensionId, $lbTrafficExtension); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->createLbTrafficExtension($formattedParent, $lbTrafficExtensionId, $lbTrafficExtension); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'createLbTrafficExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the `LbTrafficExtension` resource. Must be - * in the format `projects/{project}/locations/{location}`. - * @param string $lbTrafficExtensionId Required. User-provided ID of the `LbTrafficExtension` resource to be - * created. - * @param LbTrafficExtension $lbTrafficExtension Required. `LbTrafficExtension` resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createLbTrafficExtension($parent, $lbTrafficExtensionId, $lbTrafficExtension, array $optionalArgs = []) - { - $request = new CreateLbTrafficExtensionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setLbTrafficExtensionId($lbTrafficExtensionId); - $request->setLbTrafficExtension($lbTrafficExtension); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateLbTrafficExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes the specified `LbRouteExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedName = $depServiceClient->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - * $operationResponse = $depServiceClient->deleteLbRouteExtension($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->deleteLbRouteExtension($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'deleteLbRouteExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the `LbRouteExtension` resource to delete. Must be in - * the format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteLbRouteExtension($name, array $optionalArgs = []) - { - $request = new DeleteLbRouteExtensionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteLbRouteExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes the specified `LbTrafficExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedName = $depServiceClient->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - * $operationResponse = $depServiceClient->deleteLbTrafficExtension($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->deleteLbTrafficExtension($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'deleteLbTrafficExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the `LbTrafficExtension` resource to delete. Must be - * in the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteLbTrafficExtension($name, array $optionalArgs = []) - { - $request = new DeleteLbTrafficExtensionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteLbTrafficExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of the specified `LbRouteExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedName = $depServiceClient->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - * $response = $depServiceClient->getLbRouteExtension($formattedName); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the `LbRouteExtension` resource to get. Must be in the - * format - * `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\LbRouteExtension - * - * @throws ApiException if the remote call fails - */ - public function getLbRouteExtension($name, array $optionalArgs = []) - { - $request = new GetLbRouteExtensionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLbRouteExtension', LbRouteExtension::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of the specified `LbTrafficExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedName = $depServiceClient->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - * $response = $depServiceClient->getLbTrafficExtension($formattedName); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the `LbTrafficExtension` resource to get. Must be in - * the format - * `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\LbTrafficExtension - * - * @throws ApiException if the remote call fails - */ - public function getLbTrafficExtension($name, array $optionalArgs = []) - { - $request = new GetLbTrafficExtensionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLbTrafficExtension', LbTrafficExtension::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists `LbRouteExtension` resources in a given project and location. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedParent = $depServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $depServiceClient->listLbRouteExtensions($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $depServiceClient->listLbRouteExtensions($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the `LbRouteExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. Filtering results. - * @type string $orderBy - * Optional. Hint for how to order the results. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLbRouteExtensions($parent, array $optionalArgs = []) - { - $request = new ListLbRouteExtensionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLbRouteExtensions', $optionalArgs, ListLbRouteExtensionsResponse::class, $request); - } - - /** - * Lists `LbTrafficExtension` resources in a given project and location. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $formattedParent = $depServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $depServiceClient->listLbTrafficExtensions($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $depServiceClient->listLbTrafficExtensions($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the `LbTrafficExtension` - * resources are listed, specified in the following format: - * `projects/{project}/locations/{location}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. Filtering results. - * @type string $orderBy - * Optional. Hint for how to order the results. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLbTrafficExtensions($parent, array $optionalArgs = []) - { - $request = new ListLbTrafficExtensionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLbTrafficExtensions', $optionalArgs, ListLbTrafficExtensionsResponse::class, $request); - } - - /** - * Updates the parameters of the specified `LbRouteExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $lbRouteExtension = new LbRouteExtension(); - * $operationResponse = $depServiceClient->updateLbRouteExtension($lbRouteExtension); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->updateLbRouteExtension($lbRouteExtension); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'updateLbRouteExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param LbRouteExtension $lbRouteExtension Required. `LbRouteExtension` resource being updated. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Used to specify the fields to be overwritten in the - * `LbRouteExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateLbRouteExtension($lbRouteExtension, array $optionalArgs = []) - { - $request = new UpdateLbRouteExtensionRequest(); - $requestParamHeaders = []; - $request->setLbRouteExtension($lbRouteExtension); - $requestParamHeaders['lb_route_extension.name'] = $lbRouteExtension->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateLbRouteExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of the specified `LbTrafficExtension` resource. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $lbTrafficExtension = new LbTrafficExtension(); - * $operationResponse = $depServiceClient->updateLbTrafficExtension($lbTrafficExtension); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $depServiceClient->updateLbTrafficExtension($lbTrafficExtension); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $depServiceClient->resumeOperation($operationName, 'updateLbTrafficExtension'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param LbTrafficExtension $lbTrafficExtension Required. `LbTrafficExtension` resource being updated. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Used to specify the fields to be overwritten in the - * `LbTrafficExtension` resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field is overwritten if it is in the mask. If the - * user does not specify a mask, then all fields are overwritten. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server can ignore - * the request if it has already been completed. The server guarantees - * 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, ignores the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateLbTrafficExtension($lbTrafficExtension, array $optionalArgs = []) - { - $request = new UpdateLbTrafficExtensionRequest(); - $requestParamHeaders = []; - $request->setLbTrafficExtension($lbTrafficExtension); - $requestParamHeaders['lb_traffic_extension.name'] = $lbTrafficExtension->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateLbTrafficExtension', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $response = $depServiceClient->getLocation(); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $depServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $depServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $resource = 'resource'; - * $response = $depServiceClient->getIamPolicy($resource); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $depServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $depServiceClient = new DepServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $depServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $depServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/Gapic/NetworkServicesGapicClient.php b/owl-bot-staging/NetworkServices/v1/src/V1/Gapic/NetworkServicesGapicClient.php deleted file mode 100644 index 62d0585f837e..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/Gapic/NetworkServicesGapicClient.php +++ /dev/null @@ -1,3503 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $endpointPolicyId = 'endpoint_policy_id'; - * $endpointPolicy = new EndpointPolicy(); - * $operationResponse = $networkServicesClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createEndpointPolicy'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * Many parameters require resource names to be formatted in a particular way. To - * assist with these names, this class includes a format method for each type of - * name, and additionally a parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @deprecated This class will be removed in the next major version update. - */ -class NetworkServicesGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.networkservices.v1.NetworkServices'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'networkservices.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'networkservices.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $authorizationPolicyNameTemplate; - - private static $backendServiceNameTemplate; - - private static $clientTlsPolicyNameTemplate; - - private static $endpointPolicyNameTemplate; - - private static $gatewayNameTemplate; - - private static $grpcRouteNameTemplate; - - private static $httpRouteNameTemplate; - - private static $locationNameTemplate; - - private static $meshNameTemplate; - - private static $serverTlsPolicyNameTemplate; - - private static $serviceBindingNameTemplate; - - private static $tcpRouteNameTemplate; - - private static $tlsRouteNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/network_services_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/network_services_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/network_services_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/network_services_rest_client_config.php', - ], - ], - ]; - } - - private static function getAuthorizationPolicyNameTemplate() - { - if (self::$authorizationPolicyNameTemplate == null) { - self::$authorizationPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/authorizationPolicies/{authorization_policy}'); - } - - return self::$authorizationPolicyNameTemplate; - } - - private static function getBackendServiceNameTemplate() - { - if (self::$backendServiceNameTemplate == null) { - self::$backendServiceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/backendServices/{backend_service}'); - } - - return self::$backendServiceNameTemplate; - } - - private static function getClientTlsPolicyNameTemplate() - { - if (self::$clientTlsPolicyNameTemplate == null) { - self::$clientTlsPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_policy}'); - } - - return self::$clientTlsPolicyNameTemplate; - } - - private static function getEndpointPolicyNameTemplate() - { - if (self::$endpointPolicyNameTemplate == null) { - self::$endpointPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/endpointPolicies/{endpoint_policy}'); - } - - return self::$endpointPolicyNameTemplate; - } - - private static function getGatewayNameTemplate() - { - if (self::$gatewayNameTemplate == null) { - self::$gatewayNameTemplate = new PathTemplate('projects/{project}/locations/{location}/gateways/{gateway}'); - } - - return self::$gatewayNameTemplate; - } - - private static function getGrpcRouteNameTemplate() - { - if (self::$grpcRouteNameTemplate == null) { - self::$grpcRouteNameTemplate = new PathTemplate('projects/{project}/locations/{location}/grpcRoutes/{grpc_route}'); - } - - return self::$grpcRouteNameTemplate; - } - - private static function getHttpRouteNameTemplate() - { - if (self::$httpRouteNameTemplate == null) { - self::$httpRouteNameTemplate = new PathTemplate('projects/{project}/locations/{location}/httpRoutes/{http_route}'); - } - - return self::$httpRouteNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getMeshNameTemplate() - { - if (self::$meshNameTemplate == null) { - self::$meshNameTemplate = new PathTemplate('projects/{project}/locations/{location}/meshes/{mesh}'); - } - - return self::$meshNameTemplate; - } - - private static function getServerTlsPolicyNameTemplate() - { - if (self::$serverTlsPolicyNameTemplate == null) { - self::$serverTlsPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/serverTlsPolicies/{server_tls_policy}'); - } - - return self::$serverTlsPolicyNameTemplate; - } - - private static function getServiceBindingNameTemplate() - { - if (self::$serviceBindingNameTemplate == null) { - self::$serviceBindingNameTemplate = new PathTemplate('projects/{project}/locations/{location}/serviceBindings/{service_binding}'); - } - - return self::$serviceBindingNameTemplate; - } - - private static function getTcpRouteNameTemplate() - { - if (self::$tcpRouteNameTemplate == null) { - self::$tcpRouteNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tcpRoutes/{tcp_route}'); - } - - return self::$tcpRouteNameTemplate; - } - - private static function getTlsRouteNameTemplate() - { - if (self::$tlsRouteNameTemplate == null) { - self::$tlsRouteNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tlsRoutes/{tls_route}'); - } - - return self::$tlsRouteNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'authorizationPolicy' => self::getAuthorizationPolicyNameTemplate(), - 'backendService' => self::getBackendServiceNameTemplate(), - 'clientTlsPolicy' => self::getClientTlsPolicyNameTemplate(), - 'endpointPolicy' => self::getEndpointPolicyNameTemplate(), - 'gateway' => self::getGatewayNameTemplate(), - 'grpcRoute' => self::getGrpcRouteNameTemplate(), - 'httpRoute' => self::getHttpRouteNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'mesh' => self::getMeshNameTemplate(), - 'serverTlsPolicy' => self::getServerTlsPolicyNameTemplate(), - 'serviceBinding' => self::getServiceBindingNameTemplate(), - 'tcpRoute' => self::getTcpRouteNameTemplate(), - 'tlsRoute' => self::getTlsRouteNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * authorization_policy resource. - * - * @param string $project - * @param string $location - * @param string $authorizationPolicy - * - * @return string The formatted authorization_policy resource. - */ - public static function authorizationPolicyName($project, $location, $authorizationPolicy) - { - return self::getAuthorizationPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'authorization_policy' => $authorizationPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * backend_service resource. - * - * @param string $project - * @param string $location - * @param string $backendService - * - * @return string The formatted backend_service resource. - */ - public static function backendServiceName($project, $location, $backendService) - { - return self::getBackendServiceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'backend_service' => $backendService, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * client_tls_policy resource. - * - * @param string $project - * @param string $location - * @param string $clientTlsPolicy - * - * @return string The formatted client_tls_policy resource. - */ - public static function clientTlsPolicyName($project, $location, $clientTlsPolicy) - { - return self::getClientTlsPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'client_tls_policy' => $clientTlsPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * endpoint_policy resource. - * - * @param string $project - * @param string $location - * @param string $endpointPolicy - * - * @return string The formatted endpoint_policy resource. - */ - public static function endpointPolicyName($project, $location, $endpointPolicy) - { - return self::getEndpointPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'endpoint_policy' => $endpointPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a gateway - * resource. - * - * @param string $project - * @param string $location - * @param string $gateway - * - * @return string The formatted gateway resource. - */ - public static function gatewayName($project, $location, $gateway) - { - return self::getGatewayNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'gateway' => $gateway, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a grpc_route - * resource. - * - * @param string $project - * @param string $location - * @param string $grpcRoute - * - * @return string The formatted grpc_route resource. - */ - public static function grpcRouteName($project, $location, $grpcRoute) - { - return self::getGrpcRouteNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'grpc_route' => $grpcRoute, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a http_route - * resource. - * - * @param string $project - * @param string $location - * @param string $httpRoute - * - * @return string The formatted http_route resource. - */ - public static function httpRouteName($project, $location, $httpRoute) - { - return self::getHttpRouteNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'http_route' => $httpRoute, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a mesh - * resource. - * - * @param string $project - * @param string $location - * @param string $mesh - * - * @return string The formatted mesh resource. - */ - public static function meshName($project, $location, $mesh) - { - return self::getMeshNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'mesh' => $mesh, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * server_tls_policy resource. - * - * @param string $project - * @param string $location - * @param string $serverTlsPolicy - * - * @return string The formatted server_tls_policy resource. - */ - public static function serverTlsPolicyName($project, $location, $serverTlsPolicy) - { - return self::getServerTlsPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'server_tls_policy' => $serverTlsPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * service_binding resource. - * - * @param string $project - * @param string $location - * @param string $serviceBinding - * - * @return string The formatted service_binding resource. - */ - public static function serviceBindingName($project, $location, $serviceBinding) - { - return self::getServiceBindingNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'service_binding' => $serviceBinding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a tcp_route - * resource. - * - * @param string $project - * @param string $location - * @param string $tcpRoute - * - * @return string The formatted tcp_route resource. - */ - public static function tcpRouteName($project, $location, $tcpRoute) - { - return self::getTcpRouteNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'tcp_route' => $tcpRoute, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a tls_route - * resource. - * - * @param string $project - * @param string $location - * @param string $tlsRoute - * - * @return string The formatted tls_route resource. - */ - public static function tlsRouteName($project, $location, $tlsRoute) - { - return self::getTlsRouteNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'tls_route' => $tlsRoute, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - authorizationPolicy: projects/{project}/locations/{location}/authorizationPolicies/{authorization_policy} - * - backendService: projects/{project}/locations/{location}/backendServices/{backend_service} - * - clientTlsPolicy: projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_policy} - * - endpointPolicy: projects/{project}/locations/{location}/endpointPolicies/{endpoint_policy} - * - gateway: projects/{project}/locations/{location}/gateways/{gateway} - * - grpcRoute: projects/{project}/locations/{location}/grpcRoutes/{grpc_route} - * - httpRoute: projects/{project}/locations/{location}/httpRoutes/{http_route} - * - location: projects/{project}/locations/{location} - * - mesh: projects/{project}/locations/{location}/meshes/{mesh} - * - serverTlsPolicy: projects/{project}/locations/{location}/serverTlsPolicies/{server_tls_policy} - * - serviceBinding: projects/{project}/locations/{location}/serviceBindings/{service_binding} - * - tcpRoute: projects/{project}/locations/{location}/tcpRoutes/{tcp_route} - * - tlsRoute: projects/{project}/locations/{location}/tlsRoutes/{tls_route} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'networkservices.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new EndpointPolicy in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $endpointPolicyId = 'endpoint_policy_id'; - * $endpointPolicy = new EndpointPolicy(); - * $operationResponse = $networkServicesClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createEndpointPolicy'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the EndpointPolicy. Must be in the - * format `projects/*/locations/global`. - * @param string $endpointPolicyId Required. Short name of the EndpointPolicy resource to be created. - * E.g. "CustomECS". - * @param EndpointPolicy $endpointPolicy Required. EndpointPolicy resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createEndpointPolicy($parent, $endpointPolicyId, $endpointPolicy, array $optionalArgs = []) - { - $request = new CreateEndpointPolicyRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setEndpointPolicyId($endpointPolicyId); - $request->setEndpointPolicy($endpointPolicy); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateEndpointPolicy', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new Gateway in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $gatewayId = 'gateway_id'; - * $gateway = new Gateway(); - * $operationResponse = $networkServicesClient->createGateway($formattedParent, $gatewayId, $gateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createGateway($formattedParent, $gatewayId, $gateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the Gateway. Must be in the - * format `projects/*/locations/*`. - * @param string $gatewayId Required. Short name of the Gateway resource to be created. - * @param Gateway $gateway Required. Gateway resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createGateway($parent, $gatewayId, $gateway, array $optionalArgs = []) - { - $request = new CreateGatewayRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGatewayId($gatewayId); - $request->setGateway($gateway); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new GrpcRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $grpcRouteId = 'grpc_route_id'; - * $grpcRoute = new GrpcRoute(); - * $operationResponse = $networkServicesClient->createGrpcRoute($formattedParent, $grpcRouteId, $grpcRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createGrpcRoute($formattedParent, $grpcRouteId, $grpcRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createGrpcRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the GrpcRoute. Must be in the - * format `projects/*/locations/global`. - * @param string $grpcRouteId Required. Short name of the GrpcRoute resource to be created. - * @param GrpcRoute $grpcRoute Required. GrpcRoute resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createGrpcRoute($parent, $grpcRouteId, $grpcRoute, array $optionalArgs = []) - { - $request = new CreateGrpcRouteRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGrpcRouteId($grpcRouteId); - $request->setGrpcRoute($grpcRoute); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateGrpcRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new HttpRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $httpRouteId = 'http_route_id'; - * $httpRoute = new HttpRoute(); - * $operationResponse = $networkServicesClient->createHttpRoute($formattedParent, $httpRouteId, $httpRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createHttpRoute($formattedParent, $httpRouteId, $httpRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createHttpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the HttpRoute. Must be in the - * format `projects/*/locations/global`. - * @param string $httpRouteId Required. Short name of the HttpRoute resource to be created. - * @param HttpRoute $httpRoute Required. HttpRoute resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createHttpRoute($parent, $httpRouteId, $httpRoute, array $optionalArgs = []) - { - $request = new CreateHttpRouteRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setHttpRouteId($httpRouteId); - $request->setHttpRoute($httpRoute); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateHttpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new Mesh in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $meshId = 'mesh_id'; - * $mesh = new Mesh(); - * $operationResponse = $networkServicesClient->createMesh($formattedParent, $meshId, $mesh); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createMesh($formattedParent, $meshId, $mesh); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createMesh'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the Mesh. Must be in the - * format `projects/*/locations/global`. - * @param string $meshId Required. Short name of the Mesh resource to be created. - * @param Mesh $mesh Required. Mesh resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createMesh($parent, $meshId, $mesh, array $optionalArgs = []) - { - $request = new CreateMeshRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setMeshId($meshId); - $request->setMesh($mesh); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateMesh', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new ServiceBinding in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $serviceBindingId = 'service_binding_id'; - * $serviceBinding = new ServiceBinding(); - * $operationResponse = $networkServicesClient->createServiceBinding($formattedParent, $serviceBindingId, $serviceBinding); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createServiceBinding($formattedParent, $serviceBindingId, $serviceBinding); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createServiceBinding'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the ServiceBinding. Must be in the - * format `projects/*/locations/global`. - * @param string $serviceBindingId Required. Short name of the ServiceBinding resource to be created. - * @param ServiceBinding $serviceBinding Required. ServiceBinding resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createServiceBinding($parent, $serviceBindingId, $serviceBinding, array $optionalArgs = []) - { - $request = new CreateServiceBindingRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setServiceBindingId($serviceBindingId); - $request->setServiceBinding($serviceBinding); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateServiceBinding', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new TcpRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $tcpRouteId = 'tcp_route_id'; - * $tcpRoute = new TcpRoute(); - * $operationResponse = $networkServicesClient->createTcpRoute($formattedParent, $tcpRouteId, $tcpRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createTcpRoute($formattedParent, $tcpRouteId, $tcpRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createTcpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the TcpRoute. Must be in the - * format `projects/*/locations/global`. - * @param string $tcpRouteId Required. Short name of the TcpRoute resource to be created. - * @param TcpRoute $tcpRoute Required. TcpRoute resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createTcpRoute($parent, $tcpRouteId, $tcpRoute, array $optionalArgs = []) - { - $request = new CreateTcpRouteRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setTcpRouteId($tcpRouteId); - $request->setTcpRoute($tcpRoute); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateTcpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new TlsRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * $tlsRouteId = 'tls_route_id'; - * $tlsRoute = new TlsRoute(); - * $operationResponse = $networkServicesClient->createTlsRoute($formattedParent, $tlsRouteId, $tlsRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->createTlsRoute($formattedParent, $tlsRouteId, $tlsRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'createTlsRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the TlsRoute. Must be in the - * format `projects/*/locations/global`. - * @param string $tlsRouteId Required. Short name of the TlsRoute resource to be created. - * @param TlsRoute $tlsRoute Required. TlsRoute resource to be created. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createTlsRoute($parent, $tlsRouteId, $tlsRoute, array $optionalArgs = []) - { - $request = new CreateTlsRouteRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setTlsRouteId($tlsRouteId); - $request->setTlsRoute($tlsRoute); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateTlsRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single EndpointPolicy. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - * $operationResponse = $networkServicesClient->deleteEndpointPolicy($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteEndpointPolicy($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteEndpointPolicy'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the EndpointPolicy to delete. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteEndpointPolicy($name, array $optionalArgs = []) - { - $request = new DeleteEndpointPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteEndpointPolicy', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single Gateway. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - * $operationResponse = $networkServicesClient->deleteGateway($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteGateway($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the Gateway to delete. Must be in the format - * `projects/*/locations/*/gateways/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteGateway($name, array $optionalArgs = []) - { - $request = new DeleteGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single GrpcRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - * $operationResponse = $networkServicesClient->deleteGrpcRoute($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteGrpcRoute($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteGrpcRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the GrpcRoute to delete. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteGrpcRoute($name, array $optionalArgs = []) - { - $request = new DeleteGrpcRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteGrpcRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single HttpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - * $operationResponse = $networkServicesClient->deleteHttpRoute($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteHttpRoute($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteHttpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the HttpRoute to delete. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteHttpRoute($name, array $optionalArgs = []) - { - $request = new DeleteHttpRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteHttpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single Mesh. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - * $operationResponse = $networkServicesClient->deleteMesh($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteMesh($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteMesh'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the Mesh to delete. Must be in the format - * `projects/*/locations/global/meshes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteMesh($name, array $optionalArgs = []) - { - $request = new DeleteMeshRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteMesh', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single ServiceBinding. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - * $operationResponse = $networkServicesClient->deleteServiceBinding($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteServiceBinding($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteServiceBinding'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the ServiceBinding to delete. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteServiceBinding($name, array $optionalArgs = []) - { - $request = new DeleteServiceBindingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteServiceBinding', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single TcpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - * $operationResponse = $networkServicesClient->deleteTcpRoute($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteTcpRoute($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteTcpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the TcpRoute to delete. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteTcpRoute($name, array $optionalArgs = []) - { - $request = new DeleteTcpRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteTcpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single TlsRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - * $operationResponse = $networkServicesClient->deleteTlsRoute($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->deleteTlsRoute($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'deleteTlsRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the TlsRoute to delete. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteTlsRoute($name, array $optionalArgs = []) - { - $request = new DeleteTlsRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteTlsRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single EndpointPolicy. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - * $response = $networkServicesClient->getEndpointPolicy($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the EndpointPolicy to get. Must be in the format - * `projects/*/locations/global/endpointPolicies/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\EndpointPolicy - * - * @throws ApiException if the remote call fails - */ - public function getEndpointPolicy($name, array $optionalArgs = []) - { - $request = new GetEndpointPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetEndpointPolicy', EndpointPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single Gateway. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - * $response = $networkServicesClient->getGateway($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the Gateway to get. Must be in the format - * `projects/*/locations/*/gateways/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\Gateway - * - * @throws ApiException if the remote call fails - */ - public function getGateway($name, array $optionalArgs = []) - { - $request = new GetGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetGateway', Gateway::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single GrpcRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - * $response = $networkServicesClient->getGrpcRoute($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the GrpcRoute to get. Must be in the format - * `projects/*/locations/global/grpcRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\GrpcRoute - * - * @throws ApiException if the remote call fails - */ - public function getGrpcRoute($name, array $optionalArgs = []) - { - $request = new GetGrpcRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetGrpcRoute', GrpcRoute::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single HttpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - * $response = $networkServicesClient->getHttpRoute($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the HttpRoute to get. Must be in the format - * `projects/*/locations/global/httpRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\HttpRoute - * - * @throws ApiException if the remote call fails - */ - public function getHttpRoute($name, array $optionalArgs = []) - { - $request = new GetHttpRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetHttpRoute', HttpRoute::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single Mesh. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - * $response = $networkServicesClient->getMesh($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the Mesh to get. Must be in the format - * `projects/*/locations/global/meshes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\Mesh - * - * @throws ApiException if the remote call fails - */ - public function getMesh($name, array $optionalArgs = []) - { - $request = new GetMeshRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetMesh', Mesh::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single ServiceBinding. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - * $response = $networkServicesClient->getServiceBinding($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the ServiceBinding to get. Must be in the format - * `projects/*/locations/global/serviceBindings/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\ServiceBinding - * - * @throws ApiException if the remote call fails - */ - public function getServiceBinding($name, array $optionalArgs = []) - { - $request = new GetServiceBindingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetServiceBinding', ServiceBinding::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single TcpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - * $response = $networkServicesClient->getTcpRoute($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the TcpRoute to get. Must be in the format - * `projects/*/locations/global/tcpRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\TcpRoute - * - * @throws ApiException if the remote call fails - */ - public function getTcpRoute($name, array $optionalArgs = []) - { - $request = new GetTcpRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetTcpRoute', TcpRoute::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single TlsRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedName = $networkServicesClient->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - * $response = $networkServicesClient->getTlsRoute($formattedName); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the TlsRoute to get. Must be in the format - * `projects/*/locations/global/tlsRoutes/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\NetworkServices\V1\TlsRoute - * - * @throws ApiException if the remote call fails - */ - public function getTlsRoute($name, array $optionalArgs = []) - { - $request = new GetTlsRouteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetTlsRoute', TlsRoute::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists EndpointPolicies in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listEndpointPolicies($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listEndpointPolicies($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the EndpointPolicies should - * be listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listEndpointPolicies($parent, array $optionalArgs = []) - { - $request = new ListEndpointPoliciesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListEndpointPolicies', $optionalArgs, ListEndpointPoliciesResponse::class, $request); - } - - /** - * Lists Gateways in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listGateways($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listGateways($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the Gateways should be - * listed, specified in the format `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listGateways($parent, array $optionalArgs = []) - { - $request = new ListGatewaysRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListGateways', $optionalArgs, ListGatewaysResponse::class, $request); - } - - /** - * Lists GrpcRoutes in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listGrpcRoutes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listGrpcRoutes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the GrpcRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listGrpcRoutes($parent, array $optionalArgs = []) - { - $request = new ListGrpcRoutesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListGrpcRoutes', $optionalArgs, ListGrpcRoutesResponse::class, $request); - } - - /** - * Lists HttpRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listHttpRoutes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listHttpRoutes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the HttpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listHttpRoutes($parent, array $optionalArgs = []) - { - $request = new ListHttpRoutesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListHttpRoutes', $optionalArgs, ListHttpRoutesResponse::class, $request); - } - - /** - * Lists Meshes in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listMeshes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listMeshes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the Meshes should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listMeshes($parent, array $optionalArgs = []) - { - $request = new ListMeshesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListMeshes', $optionalArgs, ListMeshesResponse::class, $request); - } - - /** - * Lists ServiceBinding in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listServiceBindings($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listServiceBindings($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the ServiceBindings should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listServiceBindings($parent, array $optionalArgs = []) - { - $request = new ListServiceBindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListServiceBindings', $optionalArgs, ListServiceBindingsResponse::class, $request); - } - - /** - * Lists TcpRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listTcpRoutes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listTcpRoutes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the TcpRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listTcpRoutes($parent, array $optionalArgs = []) - { - $request = new ListTcpRoutesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListTcpRoutes', $optionalArgs, ListTcpRoutesResponse::class, $request); - } - - /** - * Lists TlsRoute in a given project and location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $formattedParent = $networkServicesClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listTlsRoutes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listTlsRoutes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the TlsRoutes should be - * listed, specified in the format `projects/*/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listTlsRoutes($parent, array $optionalArgs = []) - { - $request = new ListTlsRoutesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListTlsRoutes', $optionalArgs, ListTlsRoutesResponse::class, $request); - } - - /** - * Updates the parameters of a single EndpointPolicy. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $endpointPolicy = new EndpointPolicy(); - * $operationResponse = $networkServicesClient->updateEndpointPolicy($endpointPolicy); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateEndpointPolicy($endpointPolicy); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateEndpointPolicy'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param EndpointPolicy $endpointPolicy Required. Updated EndpointPolicy resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * EndpointPolicy 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateEndpointPolicy($endpointPolicy, array $optionalArgs = []) - { - $request = new UpdateEndpointPolicyRequest(); - $requestParamHeaders = []; - $request->setEndpointPolicy($endpointPolicy); - $requestParamHeaders['endpoint_policy.name'] = $endpointPolicy->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateEndpointPolicy', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single Gateway. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $gateway = new Gateway(); - * $operationResponse = $networkServicesClient->updateGateway($gateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateGateway($gateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param Gateway $gateway Required. Updated Gateway resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * Gateway 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateGateway($gateway, array $optionalArgs = []) - { - $request = new UpdateGatewayRequest(); - $requestParamHeaders = []; - $request->setGateway($gateway); - $requestParamHeaders['gateway.name'] = $gateway->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single GrpcRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $grpcRoute = new GrpcRoute(); - * $operationResponse = $networkServicesClient->updateGrpcRoute($grpcRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateGrpcRoute($grpcRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateGrpcRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param GrpcRoute $grpcRoute Required. Updated GrpcRoute resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * GrpcRoute 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateGrpcRoute($grpcRoute, array $optionalArgs = []) - { - $request = new UpdateGrpcRouteRequest(); - $requestParamHeaders = []; - $request->setGrpcRoute($grpcRoute); - $requestParamHeaders['grpc_route.name'] = $grpcRoute->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateGrpcRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single HttpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $httpRoute = new HttpRoute(); - * $operationResponse = $networkServicesClient->updateHttpRoute($httpRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateHttpRoute($httpRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateHttpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param HttpRoute $httpRoute Required. Updated HttpRoute resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * HttpRoute 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateHttpRoute($httpRoute, array $optionalArgs = []) - { - $request = new UpdateHttpRouteRequest(); - $requestParamHeaders = []; - $request->setHttpRoute($httpRoute); - $requestParamHeaders['http_route.name'] = $httpRoute->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateHttpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single Mesh. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $mesh = new Mesh(); - * $operationResponse = $networkServicesClient->updateMesh($mesh); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateMesh($mesh); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateMesh'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param Mesh $mesh Required. Updated Mesh resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * Mesh 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateMesh($mesh, array $optionalArgs = []) - { - $request = new UpdateMeshRequest(); - $requestParamHeaders = []; - $request->setMesh($mesh); - $requestParamHeaders['mesh.name'] = $mesh->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateMesh', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single TcpRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $tcpRoute = new TcpRoute(); - * $operationResponse = $networkServicesClient->updateTcpRoute($tcpRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateTcpRoute($tcpRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateTcpRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param TcpRoute $tcpRoute Required. Updated TcpRoute resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * TcpRoute 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateTcpRoute($tcpRoute, array $optionalArgs = []) - { - $request = new UpdateTcpRouteRequest(); - $requestParamHeaders = []; - $request->setTcpRoute($tcpRoute); - $requestParamHeaders['tcp_route.name'] = $tcpRoute->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateTcpRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single TlsRoute. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $tlsRoute = new TlsRoute(); - * $operationResponse = $networkServicesClient->updateTlsRoute($tlsRoute); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $networkServicesClient->updateTlsRoute($tlsRoute); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $networkServicesClient->resumeOperation($operationName, 'updateTlsRoute'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param TlsRoute $tlsRoute Required. Updated TlsRoute resource. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Field mask is used to specify the fields to be overwritten in the - * TlsRoute 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 RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateTlsRoute($tlsRoute, array $optionalArgs = []) - { - $request = new UpdateTlsRouteRequest(); - $requestParamHeaders = []; - $request->setTlsRoute($tlsRoute); - $requestParamHeaders['tls_route.name'] = $tlsRoute->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateTlsRoute', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $response = $networkServicesClient->getLocation(); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $networkServicesClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $networkServicesClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $resource = 'resource'; - * $response = $networkServicesClient->getIamPolicy($resource); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $networkServicesClient->setIamPolicy($resource, $policy); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $networkServicesClient = new NetworkServicesClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $networkServicesClient->testIamPermissions($resource, $permissions); - * } finally { - * $networkServicesClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/NetworkServicesClient.php b/owl-bot-staging/NetworkServices/v1/src/V1/NetworkServicesClient.php deleted file mode 100644 index d5820d488650..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/NetworkServicesClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.cloud.networkservices.v1.DepService' => [ - 'CreateLbRouteExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\LbRouteExtension', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateLbTrafficExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\LbTrafficExtension', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteLbRouteExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteLbTrafficExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateLbRouteExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\LbRouteExtension', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateLbTrafficExtension' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\LbTrafficExtension', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'ListLbRouteExtensions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLbRouteExtensions', - ], - ], - 'ListLbTrafficExtensions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLbTrafficExtensions', - ], - ], - 'GetLocation' => [ - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - ], - ], -]; diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_rest_client_config.php b/owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_rest_client_config.php deleted file mode 100644 index 00779b775bb0..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/resources/dep_service_rest_client_config.php +++ /dev/null @@ -1,349 +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.networkservices.v1.DepService' => [ - 'CreateLbRouteExtension' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/lbRouteExtensions', - 'body' => 'lb_route_extension', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'lb_route_extension_id', - ], - ], - 'CreateLbTrafficExtension' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/lbTrafficExtensions', - 'body' => 'lb_traffic_extension', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'lb_traffic_extension_id', - ], - ], - 'DeleteLbRouteExtension' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/lbRouteExtensions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteLbTrafficExtension' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/lbTrafficExtensions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetLbRouteExtension' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/lbRouteExtensions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetLbTrafficExtension' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/lbTrafficExtensions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLbRouteExtensions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/lbRouteExtensions', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListLbTrafficExtensions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/lbTrafficExtensions', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateLbRouteExtension' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{lb_route_extension.name=projects/*/locations/*/lbRouteExtensions/*}', - 'body' => 'lb_route_extension', - 'placeholders' => [ - 'lb_route_extension.name' => [ - 'getters' => [ - 'getLbRouteExtension', - 'getName', - ], - ], - ], - ], - 'UpdateLbTrafficExtension' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{lb_traffic_extension.name=projects/*/locations/*/lbTrafficExtensions/*}', - 'body' => 'lb_traffic_extension', - 'placeholders' => [ - 'lb_traffic_extension.name' => [ - 'getters' => [ - 'getLbTrafficExtension', - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}: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/NetworkServices/v1/src/V1/resources/network_services_client_config.json b/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_client_config.json deleted file mode 100644 index 39cf35750a4b..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_client_config.json +++ /dev/null @@ -1,252 +0,0 @@ -{ - "interfaces": { - "google.cloud.networkservices.v1.NetworkServices": { - "retry_codes": { - "no_retry_codes": [], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateEndpointPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateGrpcRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateHttpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateMesh": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateServiceBinding": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateTcpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateTlsRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteEndpointPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteGrpcRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteHttpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteMesh": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteServiceBinding": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteTcpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteTlsRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetEndpointPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetGrpcRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetHttpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetMesh": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetServiceBinding": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetTcpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetTlsRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListEndpointPolicies": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListGateways": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListGrpcRoutes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListHttpRoutes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListMeshes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListServiceBindings": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListTcpRoutes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListTlsRoutes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateEndpointPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateGrpcRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateHttpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateMesh": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateTcpRoute": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateTlsRoute": { - "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_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_descriptor_config.php b/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_descriptor_config.php deleted file mode 100644 index 41cddfb811e0..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_descriptor_config.php +++ /dev/null @@ -1,361 +0,0 @@ - [ - 'google.cloud.networkservices.v1.NetworkServices' => [ - 'CreateEndpointPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\EndpointPolicy', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\Gateway', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateGrpcRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\GrpcRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateHttpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\HttpRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateMesh' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\Mesh', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateServiceBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\ServiceBinding', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateTcpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\TcpRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateTlsRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\TlsRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteEndpointPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteGrpcRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteHttpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteMesh' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteServiceBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteTcpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteTlsRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateEndpointPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\EndpointPolicy', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\Gateway', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateGrpcRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\GrpcRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateHttpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\HttpRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateMesh' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\Mesh', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateTcpRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\TcpRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateTlsRoute' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\NetworkServices\V1\TlsRoute', - 'metadataReturnType' => '\Google\Cloud\NetworkServices\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'ListEndpointPolicies' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getEndpointPolicies', - ], - ], - 'ListGateways' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGateways', - ], - ], - 'ListGrpcRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGrpcRoutes', - ], - ], - 'ListHttpRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getHttpRoutes', - ], - ], - 'ListMeshes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getMeshes', - ], - ], - 'ListServiceBindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getServiceBindings', - ], - ], - 'ListTcpRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getTcpRoutes', - ], - ], - 'ListTlsRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getTlsRoutes', - ], - ], - 'GetLocation' => [ - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - ], - ], -]; diff --git a/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_rest_client_config.php b/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_rest_client_config.php deleted file mode 100644 index ca9776abdda5..000000000000 --- a/owl-bot-staging/NetworkServices/v1/src/V1/resources/network_services_rest_client_config.php +++ /dev/null @@ -1,702 +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.networkservices.v1.NetworkServices' => [ - 'CreateEndpointPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/endpointPolicies', - 'body' => 'endpoint_policy', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'endpoint_policy_id', - ], - ], - 'CreateGateway' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/gateways', - 'body' => 'gateway', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'gateway_id', - ], - ], - 'CreateGrpcRoute' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/grpcRoutes', - 'body' => 'grpc_route', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'grpc_route_id', - ], - ], - 'CreateHttpRoute' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/httpRoutes', - 'body' => 'http_route', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'http_route_id', - ], - ], - 'CreateMesh' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/meshes', - 'body' => 'mesh', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'mesh_id', - ], - ], - 'CreateServiceBinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/serviceBindings', - 'body' => 'service_binding', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'service_binding_id', - ], - ], - 'CreateTcpRoute' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/tcpRoutes', - 'body' => 'tcp_route', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'tcp_route_id', - ], - ], - 'CreateTlsRoute' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/tlsRoutes', - 'body' => 'tls_route', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'tls_route_id', - ], - ], - 'DeleteEndpointPolicy' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/endpointPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteGateway' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/gateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteGrpcRoute' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/grpcRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteHttpRoute' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/httpRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteMesh' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/meshes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteServiceBinding' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/serviceBindings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteTcpRoute' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/tcpRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteTlsRoute' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/tlsRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetEndpointPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/endpointPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetGateway' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/gateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetGrpcRoute' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/grpcRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetHttpRoute' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/httpRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetMesh' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/meshes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetServiceBinding' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/serviceBindings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetTcpRoute' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/tcpRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetTlsRoute' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/tlsRoutes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListEndpointPolicies' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/endpointPolicies', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListGateways' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/gateways', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListGrpcRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/grpcRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListHttpRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/httpRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListMeshes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/meshes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListServiceBindings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/serviceBindings', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListTcpRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/tcpRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListTlsRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/tlsRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateEndpointPolicy' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{endpoint_policy.name=projects/*/locations/*/endpointPolicies/*}', - 'body' => 'endpoint_policy', - 'placeholders' => [ - 'endpoint_policy.name' => [ - 'getters' => [ - 'getEndpointPolicy', - 'getName', - ], - ], - ], - ], - 'UpdateGateway' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{gateway.name=projects/*/locations/*/gateways/*}', - 'body' => 'gateway', - 'placeholders' => [ - 'gateway.name' => [ - 'getters' => [ - 'getGateway', - 'getName', - ], - ], - ], - ], - 'UpdateGrpcRoute' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{grpc_route.name=projects/*/locations/*/grpcRoutes/*}', - 'body' => 'grpc_route', - 'placeholders' => [ - 'grpc_route.name' => [ - 'getters' => [ - 'getGrpcRoute', - 'getName', - ], - ], - ], - ], - 'UpdateHttpRoute' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{http_route.name=projects/*/locations/*/httpRoutes/*}', - 'body' => 'http_route', - 'placeholders' => [ - 'http_route.name' => [ - 'getters' => [ - 'getHttpRoute', - 'getName', - ], - ], - ], - ], - 'UpdateMesh' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{mesh.name=projects/*/locations/*/meshes/*}', - 'body' => 'mesh', - 'placeholders' => [ - 'mesh.name' => [ - 'getters' => [ - 'getMesh', - 'getName', - ], - ], - ], - ], - 'UpdateTcpRoute' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{tcp_route.name=projects/*/locations/*/tcpRoutes/*}', - 'body' => 'tcp_route', - 'placeholders' => [ - 'tcp_route.name' => [ - 'getters' => [ - 'getTcpRoute', - 'getName', - ], - ], - ], - ], - 'UpdateTlsRoute' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{tls_route.name=projects/*/locations/*/tlsRoutes/*}', - 'body' => 'tls_route', - 'placeholders' => [ - 'tls_route.name' => [ - 'getters' => [ - 'getTlsRoute', - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheKeysets/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheOrigins/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/edgeCacheServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/endpointPolicies/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/serviceBindings/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/meshes/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/gateways/*}: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/NetworkServices/v1/tests/Unit/V1/DepServiceClientTest.php b/owl-bot-staging/NetworkServices/v1/tests/Unit/V1/DepServiceClientTest.php deleted file mode 100644 index 4941a961fba3..000000000000 --- a/owl-bot-staging/NetworkServices/v1/tests/Unit/V1/DepServiceClientTest.php +++ /dev/null @@ -1,1442 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DepServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DepServiceClient($options); - } - - /** @test */ - public function createLbRouteExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createLbRouteExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new LbRouteExtension(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createLbRouteExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $lbRouteExtensionId = 'lbRouteExtensionId1673910458'; - $lbRouteExtension = new LbRouteExtension(); - $lbRouteExtensionName = 'lbRouteExtensionName-498882633'; - $lbRouteExtension->setName($lbRouteExtensionName); - $lbRouteExtensionForwardingRules = []; - $lbRouteExtension->setForwardingRules($lbRouteExtensionForwardingRules); - $lbRouteExtensionExtensionChains = []; - $lbRouteExtension->setExtensionChains($lbRouteExtensionExtensionChains); - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbRouteExtension->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - $response = $gapicClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - $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.networkservices.v1.DepService/CreateLbRouteExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getLbRouteExtensionId(); - $this->assertProtobufEquals($lbRouteExtensionId, $actualValue); - $actualValue = $actualApiRequestObject->getLbRouteExtension(); - $this->assertProtobufEquals($lbRouteExtension, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLbRouteExtensionTest'); - $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 createLbRouteExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createLbRouteExtensionTest'); - $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]'); - $lbRouteExtensionId = 'lbRouteExtensionId1673910458'; - $lbRouteExtension = new LbRouteExtension(); - $lbRouteExtensionName = 'lbRouteExtensionName-498882633'; - $lbRouteExtension->setName($lbRouteExtensionName); - $lbRouteExtensionForwardingRules = []; - $lbRouteExtension->setForwardingRules($lbRouteExtensionForwardingRules); - $lbRouteExtensionExtensionChains = []; - $lbRouteExtension->setExtensionChains($lbRouteExtensionExtensionChains); - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbRouteExtension->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - $response = $gapicClient->createLbRouteExtension($formattedParent, $lbRouteExtensionId, $lbRouteExtension); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLbRouteExtensionTest'); - 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 createLbTrafficExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createLbTrafficExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new LbTrafficExtension(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createLbTrafficExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $lbTrafficExtensionId = 'lbTrafficExtensionId1573377862'; - $lbTrafficExtension = new LbTrafficExtension(); - $lbTrafficExtensionName = 'lbTrafficExtensionName1872015107'; - $lbTrafficExtension->setName($lbTrafficExtensionName); - $lbTrafficExtensionForwardingRules = []; - $lbTrafficExtension->setForwardingRules($lbTrafficExtensionForwardingRules); - $lbTrafficExtensionExtensionChains = []; - $lbTrafficExtension->setExtensionChains($lbTrafficExtensionExtensionChains); - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbTrafficExtension->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - $response = $gapicClient->createLbTrafficExtension($formattedParent, $lbTrafficExtensionId, $lbTrafficExtension); - $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.networkservices.v1.DepService/CreateLbTrafficExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getLbTrafficExtensionId(); - $this->assertProtobufEquals($lbTrafficExtensionId, $actualValue); - $actualValue = $actualApiRequestObject->getLbTrafficExtension(); - $this->assertProtobufEquals($lbTrafficExtension, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLbTrafficExtensionTest'); - $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 createLbTrafficExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createLbTrafficExtensionTest'); - $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]'); - $lbTrafficExtensionId = 'lbTrafficExtensionId1573377862'; - $lbTrafficExtension = new LbTrafficExtension(); - $lbTrafficExtensionName = 'lbTrafficExtensionName1872015107'; - $lbTrafficExtension->setName($lbTrafficExtensionName); - $lbTrafficExtensionForwardingRules = []; - $lbTrafficExtension->setForwardingRules($lbTrafficExtensionForwardingRules); - $lbTrafficExtensionExtensionChains = []; - $lbTrafficExtension->setExtensionChains($lbTrafficExtensionExtensionChains); - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbTrafficExtension->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - $response = $gapicClient->createLbTrafficExtension($formattedParent, $lbTrafficExtensionId, $lbTrafficExtension); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLbTrafficExtensionTest'); - 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 deleteLbRouteExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteLbRouteExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteLbRouteExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - $response = $gapicClient->deleteLbRouteExtension($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/DeleteLbRouteExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLbRouteExtensionTest'); - $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 deleteLbRouteExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteLbRouteExtensionTest'); - $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->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - $response = $gapicClient->deleteLbRouteExtension($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLbRouteExtensionTest'); - 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 deleteLbTrafficExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteLbTrafficExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteLbTrafficExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - $response = $gapicClient->deleteLbTrafficExtension($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/DeleteLbTrafficExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLbTrafficExtensionTest'); - $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 deleteLbTrafficExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteLbTrafficExtensionTest'); - $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->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - $response = $gapicClient->deleteLbTrafficExtension($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLbTrafficExtensionTest'); - 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 getLbRouteExtensionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $expectedResponse = new LbRouteExtension(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - $response = $gapicClient->getLbRouteExtension($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/GetLbRouteExtension', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLbRouteExtensionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->lbRouteExtensionName('[PROJECT]', '[LOCATION]', '[LB_ROUTE_EXTENSION]'); - try { - $gapicClient->getLbRouteExtension($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLbTrafficExtensionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $expectedResponse = new LbTrafficExtension(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - $response = $gapicClient->getLbTrafficExtension($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/GetLbTrafficExtension', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLbTrafficExtensionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->lbTrafficExtensionName('[PROJECT]', '[LOCATION]', '[LB_TRAFFIC_EXTENSION]'); - try { - $gapicClient->getLbTrafficExtension($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLbRouteExtensionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $lbRouteExtensionsElement = new LbRouteExtension(); - $lbRouteExtensions = [ - $lbRouteExtensionsElement, - ]; - $expectedResponse = new ListLbRouteExtensionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLbRouteExtensions($lbRouteExtensions); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listLbRouteExtensions($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLbRouteExtensions()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/ListLbRouteExtensions', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLbRouteExtensionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listLbRouteExtensions($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLbTrafficExtensionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $lbTrafficExtensionsElement = new LbTrafficExtension(); - $lbTrafficExtensions = [ - $lbTrafficExtensionsElement, - ]; - $expectedResponse = new ListLbTrafficExtensionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLbTrafficExtensions($lbTrafficExtensions); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listLbTrafficExtensions($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLbTrafficExtensions()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.DepService/ListLbTrafficExtensions', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLbTrafficExtensionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listLbTrafficExtensions($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateLbRouteExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateLbRouteExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new LbRouteExtension(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateLbRouteExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $lbRouteExtension = new LbRouteExtension(); - $lbRouteExtensionName = 'lbRouteExtensionName-498882633'; - $lbRouteExtension->setName($lbRouteExtensionName); - $lbRouteExtensionForwardingRules = []; - $lbRouteExtension->setForwardingRules($lbRouteExtensionForwardingRules); - $lbRouteExtensionExtensionChains = []; - $lbRouteExtension->setExtensionChains($lbRouteExtensionExtensionChains); - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbRouteExtension->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - $response = $gapicClient->updateLbRouteExtension($lbRouteExtension); - $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.networkservices.v1.DepService/UpdateLbRouteExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getLbRouteExtension(); - $this->assertProtobufEquals($lbRouteExtension, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLbRouteExtensionTest'); - $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 updateLbRouteExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateLbRouteExtensionTest'); - $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 - $lbRouteExtension = new LbRouteExtension(); - $lbRouteExtensionName = 'lbRouteExtensionName-498882633'; - $lbRouteExtension->setName($lbRouteExtensionName); - $lbRouteExtensionForwardingRules = []; - $lbRouteExtension->setForwardingRules($lbRouteExtensionForwardingRules); - $lbRouteExtensionExtensionChains = []; - $lbRouteExtension->setExtensionChains($lbRouteExtensionExtensionChains); - $lbRouteExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbRouteExtension->setLoadBalancingScheme($lbRouteExtensionLoadBalancingScheme); - $response = $gapicClient->updateLbRouteExtension($lbRouteExtension); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLbRouteExtensionTest'); - 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 updateLbTrafficExtensionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateLbTrafficExtensionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new LbTrafficExtension(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateLbTrafficExtensionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $lbTrafficExtension = new LbTrafficExtension(); - $lbTrafficExtensionName = 'lbTrafficExtensionName1872015107'; - $lbTrafficExtension->setName($lbTrafficExtensionName); - $lbTrafficExtensionForwardingRules = []; - $lbTrafficExtension->setForwardingRules($lbTrafficExtensionForwardingRules); - $lbTrafficExtensionExtensionChains = []; - $lbTrafficExtension->setExtensionChains($lbTrafficExtensionExtensionChains); - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbTrafficExtension->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - $response = $gapicClient->updateLbTrafficExtension($lbTrafficExtension); - $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.networkservices.v1.DepService/UpdateLbTrafficExtension', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getLbTrafficExtension(); - $this->assertProtobufEquals($lbTrafficExtension, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLbTrafficExtensionTest'); - $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 updateLbTrafficExtensionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateLbTrafficExtensionTest'); - $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 - $lbTrafficExtension = new LbTrafficExtension(); - $lbTrafficExtensionName = 'lbTrafficExtensionName1872015107'; - $lbTrafficExtension->setName($lbTrafficExtensionName); - $lbTrafficExtensionForwardingRules = []; - $lbTrafficExtension->setForwardingRules($lbTrafficExtensionForwardingRules); - $lbTrafficExtensionExtensionChains = []; - $lbTrafficExtension->setExtensionChains($lbTrafficExtensionExtensionChains); - $lbTrafficExtensionLoadBalancingScheme = LoadBalancingScheme::LOAD_BALANCING_SCHEME_UNSPECIFIED; - $lbTrafficExtension->setLoadBalancingScheme($lbTrafficExtensionLoadBalancingScheme); - $response = $gapicClient->updateLbTrafficExtension($lbTrafficExtension); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLbTrafficExtensionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/NetworkServices/v1/tests/Unit/V1/NetworkServicesClientTest.php b/owl-bot-staging/NetworkServices/v1/tests/Unit/V1/NetworkServicesClientTest.php deleted file mode 100644 index bb3e3d923e70..000000000000 --- a/owl-bot-staging/NetworkServices/v1/tests/Unit/V1/NetworkServicesClientTest.php +++ /dev/null @@ -1,4472 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return NetworkServicesClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new NetworkServicesClient($options); - } - - /** @test */ - public function createEndpointPolicyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createEndpointPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $authorizationPolicy = 'authorizationPolicy-1576667208'; - $description = 'description-1724546052'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $clientTlsPolicy = 'clientTlsPolicy-611416598'; - $expectedResponse = new EndpointPolicy(); - $expectedResponse->setName($name); - $expectedResponse->setAuthorizationPolicy($authorizationPolicy); - $expectedResponse->setDescription($description); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $expectedResponse->setClientTlsPolicy($clientTlsPolicy); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createEndpointPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $endpointPolicyId = 'endpointPolicyId-969914082'; - $endpointPolicy = new EndpointPolicy(); - $endpointPolicyName = 'endpointPolicyName36531794'; - $endpointPolicy->setName($endpointPolicyName); - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - $endpointPolicy->setType($endpointPolicyType); - $endpointPolicyEndpointMatcher = new EndpointMatcher(); - $endpointPolicy->setEndpointMatcher($endpointPolicyEndpointMatcher); - $response = $gapicClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - $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.networkservices.v1.NetworkServices/CreateEndpointPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getEndpointPolicyId(); - $this->assertProtobufEquals($endpointPolicyId, $actualValue); - $actualValue = $actualApiRequestObject->getEndpointPolicy(); - $this->assertProtobufEquals($endpointPolicy, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createEndpointPolicyTest'); - $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 createEndpointPolicyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createEndpointPolicyTest'); - $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]'); - $endpointPolicyId = 'endpointPolicyId-969914082'; - $endpointPolicy = new EndpointPolicy(); - $endpointPolicyName = 'endpointPolicyName36531794'; - $endpointPolicy->setName($endpointPolicyName); - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - $endpointPolicy->setType($endpointPolicyType); - $endpointPolicyEndpointMatcher = new EndpointMatcher(); - $endpointPolicy->setEndpointMatcher($endpointPolicyEndpointMatcher); - $response = $gapicClient->createEndpointPolicy($formattedParent, $endpointPolicyId, $endpointPolicy); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createEndpointPolicyTest'); - 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 createGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $scope = 'scope109264468'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $expectedResponse = new Gateway(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setScope($scope); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $gatewayId = 'gatewayId955798774'; - $gateway = new Gateway(); - $gatewayName = 'gatewayName-435522833'; - $gateway->setName($gatewayName); - $gatewayPorts = []; - $gateway->setPorts($gatewayPorts); - $gatewayScope = 'gatewayScope-611626384'; - $gateway->setScope($gatewayScope); - $response = $gapicClient->createGateway($formattedParent, $gatewayId, $gateway); - $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.networkservices.v1.NetworkServices/CreateGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getGatewayId(); - $this->assertProtobufEquals($gatewayId, $actualValue); - $actualValue = $actualApiRequestObject->getGateway(); - $this->assertProtobufEquals($gateway, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createGatewayTest'); - $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 createGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createGatewayTest'); - $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]'); - $gatewayId = 'gatewayId955798774'; - $gateway = new Gateway(); - $gatewayName = 'gatewayName-435522833'; - $gateway->setName($gatewayName); - $gatewayPorts = []; - $gateway->setPorts($gatewayPorts); - $gatewayScope = 'gatewayScope-611626384'; - $gateway->setScope($gatewayScope); - $response = $gapicClient->createGateway($formattedParent, $gatewayId, $gateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createGatewayTest'); - 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 createGrpcRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createGrpcRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new GrpcRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createGrpcRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $grpcRouteId = 'grpcRouteId100668882'; - $grpcRoute = new GrpcRoute(); - $grpcRouteName = 'grpcRouteName-2118800906'; - $grpcRoute->setName($grpcRouteName); - $grpcRouteHostnames = []; - $grpcRoute->setHostnames($grpcRouteHostnames); - $grpcRouteRules = []; - $grpcRoute->setRules($grpcRouteRules); - $response = $gapicClient->createGrpcRoute($formattedParent, $grpcRouteId, $grpcRoute); - $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.networkservices.v1.NetworkServices/CreateGrpcRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getGrpcRouteId(); - $this->assertProtobufEquals($grpcRouteId, $actualValue); - $actualValue = $actualApiRequestObject->getGrpcRoute(); - $this->assertProtobufEquals($grpcRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createGrpcRouteTest'); - $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 createGrpcRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createGrpcRouteTest'); - $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]'); - $grpcRouteId = 'grpcRouteId100668882'; - $grpcRoute = new GrpcRoute(); - $grpcRouteName = 'grpcRouteName-2118800906'; - $grpcRoute->setName($grpcRouteName); - $grpcRouteHostnames = []; - $grpcRoute->setHostnames($grpcRouteHostnames); - $grpcRouteRules = []; - $grpcRoute->setRules($grpcRouteRules); - $response = $gapicClient->createGrpcRoute($formattedParent, $grpcRouteId, $grpcRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createGrpcRouteTest'); - 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 createHttpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createHttpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new HttpRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createHttpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $httpRouteId = 'httpRouteId-1087115096'; - $httpRoute = new HttpRoute(); - $httpRouteName = 'httpRouteName988382412'; - $httpRoute->setName($httpRouteName); - $httpRouteHostnames = []; - $httpRoute->setHostnames($httpRouteHostnames); - $httpRouteRules = []; - $httpRoute->setRules($httpRouteRules); - $response = $gapicClient->createHttpRoute($formattedParent, $httpRouteId, $httpRoute); - $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.networkservices.v1.NetworkServices/CreateHttpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getHttpRouteId(); - $this->assertProtobufEquals($httpRouteId, $actualValue); - $actualValue = $actualApiRequestObject->getHttpRoute(); - $this->assertProtobufEquals($httpRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createHttpRouteTest'); - $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 createHttpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createHttpRouteTest'); - $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]'); - $httpRouteId = 'httpRouteId-1087115096'; - $httpRoute = new HttpRoute(); - $httpRouteName = 'httpRouteName988382412'; - $httpRoute->setName($httpRouteName); - $httpRouteHostnames = []; - $httpRoute->setHostnames($httpRouteHostnames); - $httpRouteRules = []; - $httpRoute->setRules($httpRouteRules); - $response = $gapicClient->createHttpRoute($formattedParent, $httpRouteId, $httpRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createHttpRouteTest'); - 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 createMeshTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createMeshTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $interceptionPort = 537115930; - $expectedResponse = new Mesh(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setInterceptionPort($interceptionPort); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createMeshTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $meshId = 'meshId954595501'; - $mesh = new Mesh(); - $meshName = 'meshName-472824296'; - $mesh->setName($meshName); - $response = $gapicClient->createMesh($formattedParent, $meshId, $mesh); - $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.networkservices.v1.NetworkServices/CreateMesh', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getMeshId(); - $this->assertProtobufEquals($meshId, $actualValue); - $actualValue = $actualApiRequestObject->getMesh(); - $this->assertProtobufEquals($mesh, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createMeshTest'); - $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 createMeshExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createMeshTest'); - $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]'); - $meshId = 'meshId954595501'; - $mesh = new Mesh(); - $meshName = 'meshName-472824296'; - $mesh->setName($meshName); - $response = $gapicClient->createMesh($formattedParent, $meshId, $mesh); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createMeshTest'); - 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 createServiceBindingTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createServiceBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $service = 'service1984153269'; - $expectedResponse = new ServiceBinding(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setService($service); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createServiceBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $serviceBindingId = 'serviceBindingId-2088291105'; - $serviceBinding = new ServiceBinding(); - $serviceBindingName = 'serviceBindingName985981115'; - $serviceBinding->setName($serviceBindingName); - $serviceBindingService = 'serviceBindingService344355461'; - $serviceBinding->setService($serviceBindingService); - $response = $gapicClient->createServiceBinding($formattedParent, $serviceBindingId, $serviceBinding); - $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.networkservices.v1.NetworkServices/CreateServiceBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getServiceBindingId(); - $this->assertProtobufEquals($serviceBindingId, $actualValue); - $actualValue = $actualApiRequestObject->getServiceBinding(); - $this->assertProtobufEquals($serviceBinding, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceBindingTest'); - $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 createServiceBindingExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createServiceBindingTest'); - $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]'); - $serviceBindingId = 'serviceBindingId-2088291105'; - $serviceBinding = new ServiceBinding(); - $serviceBindingName = 'serviceBindingName985981115'; - $serviceBinding->setName($serviceBindingName); - $serviceBindingService = 'serviceBindingService344355461'; - $serviceBinding->setService($serviceBindingService); - $response = $gapicClient->createServiceBinding($formattedParent, $serviceBindingId, $serviceBinding); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceBindingTest'); - 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 createTcpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createTcpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TcpRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createTcpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $tcpRouteId = 'tcpRouteId-154571409'; - $tcpRoute = new TcpRoute(); - $tcpRouteName = 'tcpRouteName1920926099'; - $tcpRoute->setName($tcpRouteName); - $tcpRouteRules = []; - $tcpRoute->setRules($tcpRouteRules); - $response = $gapicClient->createTcpRoute($formattedParent, $tcpRouteId, $tcpRoute); - $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.networkservices.v1.NetworkServices/CreateTcpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getTcpRouteId(); - $this->assertProtobufEquals($tcpRouteId, $actualValue); - $actualValue = $actualApiRequestObject->getTcpRoute(); - $this->assertProtobufEquals($tcpRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createTcpRouteTest'); - $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 createTcpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createTcpRouteTest'); - $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]'); - $tcpRouteId = 'tcpRouteId-154571409'; - $tcpRoute = new TcpRoute(); - $tcpRouteName = 'tcpRouteName1920926099'; - $tcpRoute->setName($tcpRouteName); - $tcpRouteRules = []; - $tcpRoute->setRules($tcpRouteRules); - $response = $gapicClient->createTcpRoute($formattedParent, $tcpRouteId, $tcpRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createTcpRouteTest'); - 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 createTlsRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createTlsRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TlsRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createTlsRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $tlsRouteId = 'tlsRouteId263195029'; - $tlsRoute = new TlsRoute(); - $tlsRouteName = 'tlsRouteName-1956274759'; - $tlsRoute->setName($tlsRouteName); - $tlsRouteRules = []; - $tlsRoute->setRules($tlsRouteRules); - $response = $gapicClient->createTlsRoute($formattedParent, $tlsRouteId, $tlsRoute); - $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.networkservices.v1.NetworkServices/CreateTlsRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getTlsRouteId(); - $this->assertProtobufEquals($tlsRouteId, $actualValue); - $actualValue = $actualApiRequestObject->getTlsRoute(); - $this->assertProtobufEquals($tlsRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createTlsRouteTest'); - $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 createTlsRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createTlsRouteTest'); - $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]'); - $tlsRouteId = 'tlsRouteId263195029'; - $tlsRoute = new TlsRoute(); - $tlsRouteName = 'tlsRouteName-1956274759'; - $tlsRoute->setName($tlsRouteName); - $tlsRouteRules = []; - $tlsRoute->setRules($tlsRouteRules); - $response = $gapicClient->createTlsRoute($formattedParent, $tlsRouteId, $tlsRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createTlsRouteTest'); - 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 deleteEndpointPolicyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteEndpointPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteEndpointPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - $response = $gapicClient->deleteEndpointPolicy($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteEndpointPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteEndpointPolicyTest'); - $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 deleteEndpointPolicyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteEndpointPolicyTest'); - $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->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - $response = $gapicClient->deleteEndpointPolicy($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteEndpointPolicyTest'); - 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 deleteGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - $response = $gapicClient->deleteGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteGatewayTest'); - $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 deleteGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteGatewayTest'); - $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->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - $response = $gapicClient->deleteGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteGatewayTest'); - 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 deleteGrpcRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteGrpcRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteGrpcRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - $response = $gapicClient->deleteGrpcRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteGrpcRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteGrpcRouteTest'); - $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 deleteGrpcRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteGrpcRouteTest'); - $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->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - $response = $gapicClient->deleteGrpcRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteGrpcRouteTest'); - 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 deleteHttpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteHttpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteHttpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - $response = $gapicClient->deleteHttpRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteHttpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteHttpRouteTest'); - $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 deleteHttpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteHttpRouteTest'); - $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->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - $response = $gapicClient->deleteHttpRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteHttpRouteTest'); - 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 deleteMeshTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteMeshTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteMeshTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - $response = $gapicClient->deleteMesh($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteMesh', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteMeshTest'); - $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 deleteMeshExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteMeshTest'); - $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->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - $response = $gapicClient->deleteMesh($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteMeshTest'); - 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 deleteServiceBindingTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteServiceBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteServiceBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - $response = $gapicClient->deleteServiceBinding($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteServiceBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteServiceBindingTest'); - $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 deleteServiceBindingExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteServiceBindingTest'); - $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->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - $response = $gapicClient->deleteServiceBinding($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteServiceBindingTest'); - 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 deleteTcpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteTcpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteTcpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - $response = $gapicClient->deleteTcpRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteTcpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteTcpRouteTest'); - $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 deleteTcpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteTcpRouteTest'); - $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->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - $response = $gapicClient->deleteTcpRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteTcpRouteTest'); - 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 deleteTlsRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteTlsRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteTlsRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - $response = $gapicClient->deleteTlsRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/DeleteTlsRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteTlsRouteTest'); - $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 deleteTlsRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteTlsRouteTest'); - $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->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - $response = $gapicClient->deleteTlsRoute($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteTlsRouteTest'); - 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 getEndpointPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $authorizationPolicy = 'authorizationPolicy-1576667208'; - $description = 'description-1724546052'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $clientTlsPolicy = 'clientTlsPolicy-611416598'; - $expectedResponse = new EndpointPolicy(); - $expectedResponse->setName($name2); - $expectedResponse->setAuthorizationPolicy($authorizationPolicy); - $expectedResponse->setDescription($description); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $expectedResponse->setClientTlsPolicy($clientTlsPolicy); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - $response = $gapicClient->getEndpointPolicy($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetEndpointPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEndpointPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->endpointPolicyName('[PROJECT]', '[LOCATION]', '[ENDPOINT_POLICY]'); - try { - $gapicClient->getEndpointPolicy($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getGatewayTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $scope = 'scope109264468'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $expectedResponse = new Gateway(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setScope($scope); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - $response = $gapicClient->getGateway($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetGateway', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getGatewayExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->gatewayName('[PROJECT]', '[LOCATION]', '[GATEWAY]'); - try { - $gapicClient->getGateway($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getGrpcRouteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new GrpcRoute(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - $response = $gapicClient->getGrpcRoute($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetGrpcRoute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getGrpcRouteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->grpcRouteName('[PROJECT]', '[LOCATION]', '[GRPC_ROUTE]'); - try { - $gapicClient->getGrpcRoute($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getHttpRouteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new HttpRoute(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - $response = $gapicClient->getHttpRoute($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetHttpRoute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getHttpRouteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->httpRouteName('[PROJECT]', '[LOCATION]', '[HTTP_ROUTE]'); - try { - $gapicClient->getHttpRoute($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMeshTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $interceptionPort = 537115930; - $expectedResponse = new Mesh(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setInterceptionPort($interceptionPort); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - $response = $gapicClient->getMesh($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetMesh', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMeshExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->meshName('[PROJECT]', '[LOCATION]', '[MESH]'); - try { - $gapicClient->getMesh($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getServiceBindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $service = 'service1984153269'; - $expectedResponse = new ServiceBinding(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setService($service); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - $response = $gapicClient->getServiceBinding($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetServiceBinding', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getServiceBindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->serviceBindingName('[PROJECT]', '[LOCATION]', '[SERVICE_BINDING]'); - try { - $gapicClient->getServiceBinding($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTcpRouteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TcpRoute(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - $response = $gapicClient->getTcpRoute($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetTcpRoute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTcpRouteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->tcpRouteName('[PROJECT]', '[LOCATION]', '[TCP_ROUTE]'); - try { - $gapicClient->getTcpRoute($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTlsRouteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TlsRoute(); - $expectedResponse->setName($name2); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - $response = $gapicClient->getTlsRoute($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/GetTlsRoute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTlsRouteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal 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->tlsRouteName('[PROJECT]', '[LOCATION]', '[TLS_ROUTE]'); - try { - $gapicClient->getTlsRoute($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEndpointPoliciesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $endpointPoliciesElement = new EndpointPolicy(); - $endpointPolicies = [ - $endpointPoliciesElement, - ]; - $expectedResponse = new ListEndpointPoliciesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setEndpointPolicies($endpointPolicies); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listEndpointPolicies($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getEndpointPolicies()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListEndpointPolicies', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEndpointPoliciesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listEndpointPolicies($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listGatewaysTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $gatewaysElement = new Gateway(); - $gateways = [ - $gatewaysElement, - ]; - $expectedResponse = new ListGatewaysResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setGateways($gateways); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listGateways($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGateways()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListGateways', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listGatewaysExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listGateways($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listGrpcRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $grpcRoutesElement = new GrpcRoute(); - $grpcRoutes = [ - $grpcRoutesElement, - ]; - $expectedResponse = new ListGrpcRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setGrpcRoutes($grpcRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listGrpcRoutes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGrpcRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListGrpcRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listGrpcRoutesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listGrpcRoutes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listHttpRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $httpRoutesElement = new HttpRoute(); - $httpRoutes = [ - $httpRoutesElement, - ]; - $expectedResponse = new ListHttpRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setHttpRoutes($httpRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listHttpRoutes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getHttpRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListHttpRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listHttpRoutesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listHttpRoutes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMeshesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $meshesElement = new Mesh(); - $meshes = [ - $meshesElement, - ]; - $expectedResponse = new ListMeshesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMeshes($meshes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listMeshes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMeshes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListMeshes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMeshesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listMeshes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listServiceBindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $serviceBindingsElement = new ServiceBinding(); - $serviceBindings = [ - $serviceBindingsElement, - ]; - $expectedResponse = new ListServiceBindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setServiceBindings($serviceBindings); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listServiceBindings($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getServiceBindings()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListServiceBindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listServiceBindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listServiceBindings($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTcpRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $tcpRoutesElement = new TcpRoute(); - $tcpRoutes = [ - $tcpRoutesElement, - ]; - $expectedResponse = new ListTcpRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTcpRoutes($tcpRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listTcpRoutes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTcpRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListTcpRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTcpRoutesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listTcpRoutes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTlsRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $tlsRoutesElement = new TlsRoute(); - $tlsRoutes = [ - $tlsRoutesElement, - ]; - $expectedResponse = new ListTlsRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTlsRoutes($tlsRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listTlsRoutes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTlsRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.networkservices.v1.NetworkServices/ListTlsRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTlsRoutesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listTlsRoutes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateEndpointPolicyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateEndpointPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $authorizationPolicy = 'authorizationPolicy-1576667208'; - $description = 'description-1724546052'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $clientTlsPolicy = 'clientTlsPolicy-611416598'; - $expectedResponse = new EndpointPolicy(); - $expectedResponse->setName($name); - $expectedResponse->setAuthorizationPolicy($authorizationPolicy); - $expectedResponse->setDescription($description); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $expectedResponse->setClientTlsPolicy($clientTlsPolicy); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateEndpointPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $endpointPolicy = new EndpointPolicy(); - $endpointPolicyName = 'endpointPolicyName36531794'; - $endpointPolicy->setName($endpointPolicyName); - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - $endpointPolicy->setType($endpointPolicyType); - $endpointPolicyEndpointMatcher = new EndpointMatcher(); - $endpointPolicy->setEndpointMatcher($endpointPolicyEndpointMatcher); - $response = $gapicClient->updateEndpointPolicy($endpointPolicy); - $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.networkservices.v1.NetworkServices/UpdateEndpointPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getEndpointPolicy(); - $this->assertProtobufEquals($endpointPolicy, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateEndpointPolicyTest'); - $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 updateEndpointPolicyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateEndpointPolicyTest'); - $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 - $endpointPolicy = new EndpointPolicy(); - $endpointPolicyName = 'endpointPolicyName36531794'; - $endpointPolicy->setName($endpointPolicyName); - $endpointPolicyType = EndpointPolicyType::ENDPOINT_POLICY_TYPE_UNSPECIFIED; - $endpointPolicy->setType($endpointPolicyType); - $endpointPolicyEndpointMatcher = new EndpointMatcher(); - $endpointPolicy->setEndpointMatcher($endpointPolicyEndpointMatcher); - $response = $gapicClient->updateEndpointPolicy($endpointPolicy); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateEndpointPolicyTest'); - 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 updateGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $scope = 'scope109264468'; - $serverTlsPolicy = 'serverTlsPolicy1906438002'; - $expectedResponse = new Gateway(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setScope($scope); - $expectedResponse->setServerTlsPolicy($serverTlsPolicy); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $gateway = new Gateway(); - $gatewayName = 'gatewayName-435522833'; - $gateway->setName($gatewayName); - $gatewayPorts = []; - $gateway->setPorts($gatewayPorts); - $gatewayScope = 'gatewayScope-611626384'; - $gateway->setScope($gatewayScope); - $response = $gapicClient->updateGateway($gateway); - $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.networkservices.v1.NetworkServices/UpdateGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getGateway(); - $this->assertProtobufEquals($gateway, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateGatewayTest'); - $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 updateGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateGatewayTest'); - $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 - $gateway = new Gateway(); - $gatewayName = 'gatewayName-435522833'; - $gateway->setName($gatewayName); - $gatewayPorts = []; - $gateway->setPorts($gatewayPorts); - $gatewayScope = 'gatewayScope-611626384'; - $gateway->setScope($gatewayScope); - $response = $gapicClient->updateGateway($gateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateGatewayTest'); - 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 updateGrpcRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateGrpcRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new GrpcRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateGrpcRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $grpcRoute = new GrpcRoute(); - $grpcRouteName = 'grpcRouteName-2118800906'; - $grpcRoute->setName($grpcRouteName); - $grpcRouteHostnames = []; - $grpcRoute->setHostnames($grpcRouteHostnames); - $grpcRouteRules = []; - $grpcRoute->setRules($grpcRouteRules); - $response = $gapicClient->updateGrpcRoute($grpcRoute); - $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.networkservices.v1.NetworkServices/UpdateGrpcRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getGrpcRoute(); - $this->assertProtobufEquals($grpcRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateGrpcRouteTest'); - $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 updateGrpcRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateGrpcRouteTest'); - $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 - $grpcRoute = new GrpcRoute(); - $grpcRouteName = 'grpcRouteName-2118800906'; - $grpcRoute->setName($grpcRouteName); - $grpcRouteHostnames = []; - $grpcRoute->setHostnames($grpcRouteHostnames); - $grpcRouteRules = []; - $grpcRoute->setRules($grpcRouteRules); - $response = $gapicClient->updateGrpcRoute($grpcRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateGrpcRouteTest'); - 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 updateHttpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateHttpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new HttpRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateHttpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $httpRoute = new HttpRoute(); - $httpRouteName = 'httpRouteName988382412'; - $httpRoute->setName($httpRouteName); - $httpRouteHostnames = []; - $httpRoute->setHostnames($httpRouteHostnames); - $httpRouteRules = []; - $httpRoute->setRules($httpRouteRules); - $response = $gapicClient->updateHttpRoute($httpRoute); - $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.networkservices.v1.NetworkServices/UpdateHttpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getHttpRoute(); - $this->assertProtobufEquals($httpRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateHttpRouteTest'); - $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 updateHttpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateHttpRouteTest'); - $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 - $httpRoute = new HttpRoute(); - $httpRouteName = 'httpRouteName988382412'; - $httpRoute->setName($httpRouteName); - $httpRouteHostnames = []; - $httpRoute->setHostnames($httpRouteHostnames); - $httpRouteRules = []; - $httpRoute->setRules($httpRouteRules); - $response = $gapicClient->updateHttpRoute($httpRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateHttpRouteTest'); - 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 updateMeshTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateMeshTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $interceptionPort = 537115930; - $expectedResponse = new Mesh(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $expectedResponse->setInterceptionPort($interceptionPort); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateMeshTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $mesh = new Mesh(); - $meshName = 'meshName-472824296'; - $mesh->setName($meshName); - $response = $gapicClient->updateMesh($mesh); - $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.networkservices.v1.NetworkServices/UpdateMesh', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getMesh(); - $this->assertProtobufEquals($mesh, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateMeshTest'); - $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 updateMeshExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateMeshTest'); - $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 - $mesh = new Mesh(); - $meshName = 'meshName-472824296'; - $mesh->setName($meshName); - $response = $gapicClient->updateMesh($mesh); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateMeshTest'); - 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 updateTcpRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateTcpRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TcpRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateTcpRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $tcpRoute = new TcpRoute(); - $tcpRouteName = 'tcpRouteName1920926099'; - $tcpRoute->setName($tcpRouteName); - $tcpRouteRules = []; - $tcpRoute->setRules($tcpRouteRules); - $response = $gapicClient->updateTcpRoute($tcpRoute); - $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.networkservices.v1.NetworkServices/UpdateTcpRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getTcpRoute(); - $this->assertProtobufEquals($tcpRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateTcpRouteTest'); - $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 updateTcpRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateTcpRouteTest'); - $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 - $tcpRoute = new TcpRoute(); - $tcpRouteName = 'tcpRouteName1920926099'; - $tcpRoute->setName($tcpRouteName); - $tcpRouteRules = []; - $tcpRoute->setRules($tcpRouteRules); - $response = $gapicClient->updateTcpRoute($tcpRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateTcpRouteTest'); - 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 updateTlsRouteTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateTlsRouteTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $selfLink = 'selfLink-1691268851'; - $description = 'description-1724546052'; - $expectedResponse = new TlsRoute(); - $expectedResponse->setName($name); - $expectedResponse->setSelfLink($selfLink); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateTlsRouteTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $tlsRoute = new TlsRoute(); - $tlsRouteName = 'tlsRouteName-1956274759'; - $tlsRoute->setName($tlsRouteName); - $tlsRouteRules = []; - $tlsRoute->setRules($tlsRouteRules); - $response = $gapicClient->updateTlsRoute($tlsRoute); - $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.networkservices.v1.NetworkServices/UpdateTlsRoute', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getTlsRoute(); - $this->assertProtobufEquals($tlsRoute, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateTlsRouteTest'); - $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 updateTlsRouteExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateTlsRouteTest'); - $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 - $tlsRoute = new TlsRoute(); - $tlsRouteName = 'tlsRouteName-1956274759'; - $tlsRoute->setName($tlsRouteName); - $tlsRouteRules = []; - $tlsRoute->setRules($tlsRouteRules); - $response = $gapicClient->updateTlsRoute($tlsRoute); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateTlsRouteTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -}