From 312ba7fa3330b19e20f32ff6a7e6703185623a26 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Tue, 15 Oct 2024 17:32:48 -0700 Subject: [PATCH] feat: [networkmanagement] add messages and fields related to Redis Instances (#5755) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: add messages and fields related to Redis Instances feat: add messages and fields related to Redis Clusters feat: add PSC network attachment URI to the InstanceInfo proto feat: add subnet URI and region name to the NetworkInfo proto feat: add firewall policy URI to the FirewallInfo proto feat: add fields related to advertised routes to the RouteInfo proto feat: add region name field to the RouteInfo proto feat: add region name to the ForwardingRuleInfo proto feat: add load balancer name to the ForwardingRuleInfo proto feat: add PSC target fields to the ForwardingRuleInfo proto feat: add more detailed abort and drop causes to corresponding enums chore: update Google API field annotations format docs: update outdated comments in the FirewallInfo proto PiperOrigin-RevId: 686129238 Source-Link: https://github.com/googleapis/googleapis/commit/cab65d56577608266888c9800ba42c2bf4704805 Source-Link: https://github.com/googleapis/googleapis-gen/commit/cd5b0a24acc4c2824dcb0db4e969c3551a9470cf Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLW5ldHdvcmttYW5hZ2VtZW50Ly5Pd2xCb3QueWFtbCIsImgiOiJjZDViMGEyNGFjYzRjMjgyNGRjYjBkYjRlOTY5YzM1NTFhOTQ3MGNmIn0= * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot --- .../google-cloud-networkmanagement/README.md | 4 +- .../v1/connectivity_test.proto | 12 +- .../networkmanagement/v1/reachability.proto | 37 +- .../cloud/networkmanagement/v1/trace.proto | 282 +- .../v1beta1/connectivity_test.proto | 12 +- .../v1beta1/reachability.proto | 37 +- .../networkmanagement/v1beta1/trace.proto | 282 +- .../protos/protos.d.ts | 1076 +- .../protos/protos.js | 25384 +++++++++------- .../protos/protos.json | 443 +- ...ata_google.cloud.networkmanagement.v1.json | 2 +- ...oogle.cloud.networkmanagement.v1beta1.json | 2 +- .../src/v1/reachability_service_client.ts | 28 +- .../v1beta1/reachability_service_client.ts | 28 +- .../test/gapic_reachability_service_v1.ts | 40 + .../gapic_reachability_service_v1beta1.ts | 39 + 16 files changed, 16456 insertions(+), 11252 deletions(-) diff --git a/packages/google-cloud-networkmanagement/README.md b/packages/google-cloud-networkmanagement/README.md index 57ef0aa127b..de7462317bc 100644 --- a/packages/google-cloud-networkmanagement/README.md +++ b/packages/google-cloud-networkmanagement/README.md @@ -44,7 +44,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained]. 1. [Select or create a Cloud Platform project][projects]. 1. [Enable billing for your project][billing]. 1. [Enable the Network Management API API][enable_api]. -1. [Set up authentication with a service account][auth] so you can access the +1. [Set up authentication][auth] so you can access the API from your local workstation. ### Installing the client library @@ -174,4 +174,4 @@ See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/main/LICENSE) [projects]: https://console.cloud.google.com/project [billing]: https://support.google.com/cloud/answer/6293499#enable-billing [enable_api]: https://console.cloud.google.com/flows/enableapi?apiid=networkmanagement.googleapis.com -[auth]: https://cloud.google.com/docs/authentication/getting-started +[auth]: https://cloud.google.com/docs/authentication/external/set-up-adc-local diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/connectivity_test.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/connectivity_test.proto index 8fe340aeb91..0759773e2ab 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/connectivity_test.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/connectivity_test.proto @@ -37,9 +37,9 @@ message ConnectivityTest { pattern: "projects/{project}/locations/global/connectivityTests/{test}" }; - // Required. Unique name of the resource using the form: + // Identifier. Unique name of the resource using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; // The user-supplied description of the Connectivity Test. // Maximum of 512 characters. @@ -227,6 +227,14 @@ message Endpoint { // A [Cloud SQL](https://cloud.google.com/sql) instance URI. string cloud_sql_instance = 8; + // A [Redis Instance](https://cloud.google.com/memorystore/docs/redis) + // URI. + string redis_instance = 17; + + // A [Redis Cluster](https://cloud.google.com/memorystore/docs/cluster) + // URI. + string redis_cluster = 18; + // A [Cloud Function](https://cloud.google.com/functions). CloudFunctionEndpoint cloud_function = 10; diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/reachability.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/reachability.proto index 2ae3caa910a..e6ece7d335f 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/reachability.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/reachability.proto @@ -106,7 +106,7 @@ service ReachabilityService { // // If the endpoint specifications in `ConnectivityTest` are incomplete, the // reachability result returns a value of `AMBIGUOUS`. See the documentation - // in `ConnectivityTest` for for more details. + // in `ConnectivityTest` for more details. rpc UpdateConnectivityTest(UpdateConnectivityTestRequest) returns (google.longrunning.Operation) { option (google.api.http) = { @@ -162,7 +162,12 @@ service ReachabilityService { message ListConnectivityTestsRequest { // Required. The parent resource of the Connectivity Tests: // `projects/{project_id}/locations/global` - string parent = 1 [(google.api.field_behavior) = REQUIRED]; + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudresourcemanager.googleapis.com/Project" + } + ]; // Number of `ConnectivityTests` to return. int32 page_size = 2; @@ -210,14 +215,24 @@ message ListConnectivityTestsResponse { message GetConnectivityTestRequest { // Required. `ConnectivityTest` resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Request for the `CreateConnectivityTest` method. message CreateConnectivityTestRequest { // Required. The parent resource of the Connectivity Test to create: // `projects/{project_id}/locations/global` - string parent = 1 [(google.api.field_behavior) = REQUIRED]; + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudresourcemanager.googleapis.com/Project" + } + ]; // Required. The logical name of the Connectivity Test in your project // with the following restrictions: @@ -248,14 +263,24 @@ message UpdateConnectivityTestRequest { message DeleteConnectivityTestRequest { // Required. Connectivity Test resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Request for the `RerunConnectivityTest` method. message RerunConnectivityTestRequest { // Required. Connectivity Test resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Metadata describing an [Operation][google.longrunning.Operation] diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/trace.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/trace.proto index de0bbfa4883..0a39fc3ffa5 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/trace.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1/trace.proto @@ -94,6 +94,14 @@ message Step { // A CloudSQLInstanceInfo is populated with starting instance information. START_FROM_CLOUD_SQL_INSTANCE = 22; + // Initial state: packet originating from a Redis instance. + // A RedisInstanceInfo is populated with starting instance information. + START_FROM_REDIS_INSTANCE = 32; + + // Initial state: packet originating from a Redis Cluster. + // A RedisClusterInfo is populated with starting Cluster information. + START_FROM_REDIS_CLUSTER = 33; + // Initial state: packet originating from a Cloud Function. // A CloudFunctionInfo is populated with starting function information. START_FROM_CLOUD_FUNCTION = 23; @@ -115,6 +123,11 @@ message Step { // Private Service Connect. Used only for return traces. START_FROM_PSC_PUBLISHED_SERVICE = 30; + // Initial state: packet originating from a serverless network endpoint + // group backend. Used only for return traces. + // The serverless_neg information is populated. + START_FROM_SERVERLESS_NEG = 31; + // Config checking state: verify ingress firewall rule. APPLY_INGRESS_FIREWALL_RULE = 4; @@ -250,6 +263,12 @@ message Step { // Display information of a Cloud SQL instance. CloudSQLInstanceInfo cloud_sql_instance = 19; + // Display information of a Redis Instance. + RedisInstanceInfo redis_instance = 30; + + // Display information of a Redis Cluster. + RedisClusterInfo redis_cluster = 31; + // Display information of a Cloud Function. CloudFunctionInfo cloud_function = 20; @@ -270,6 +289,10 @@ message Step { // Display information of a Storage Bucket. Used only for return traces. StorageBucketInfo storage_bucket = 28; + + // Display information of a Serverless network endpoint group backend. Used + // only for return traces. + ServerlessNegInfo serverless_neg = 29; } } @@ -298,9 +321,13 @@ message InstanceInfo { // Service account authorized for the instance. string service_account = 8 [deprecated = true]; + + // URI of the PSC network attachment the NIC is attached to (if relevant). + string psc_network_attachment_uri = 9; } // For display only. Metadata associated with a Compute Engine network. +// Next ID: 7 message NetworkInfo { // Name of a Compute Engine network. string display_name = 1; @@ -308,12 +335,18 @@ message NetworkInfo { // URI of a Compute Engine network. string uri = 2; - // The IP range that matches the test. + // URI of the subnet matching the source IP address of the test. + string matched_subnet_uri = 5; + + // The IP range of the subnet matching the source IP address of the test. string matched_ip_range = 4; + + // The region of the subnet matching the source IP address of the test. + string region = 6; } // For display only. Metadata associated with a VPC firewall rule, an implied -// VPC firewall rule, or a hierarchical firewall policy rule. +// VPC firewall rule, or a firewall policy rule. message FirewallInfo { // The firewall rule's type. enum FirewallRuleType { @@ -364,12 +397,12 @@ message FirewallInfo { TRACKING_STATE = 101; } - // The display name of the VPC firewall rule. This field is not applicable - // to hierarchical firewall policy rules. + // The display name of the firewall rule. This field might be empty for + // firewall policy rules. string display_name = 1; - // The URI of the VPC firewall rule. This field is not applicable to - // implied firewall rules or hierarchical firewall policy rules. + // The URI of the firewall rule. This field is not applicable to implied + // VPC firewall rules. string uri = 2; // Possible values: INGRESS, EGRESS @@ -386,16 +419,22 @@ message FirewallInfo { string network_uri = 6; // The target tags defined by the VPC firewall rule. This field is not - // applicable to hierarchical firewall policy rules. + // applicable to firewall policy rules. repeated string target_tags = 7; // The target service accounts specified by the firewall rule. repeated string target_service_accounts = 8; - // The hierarchical firewall policy that this rule is associated with. - // This field is not applicable to VPC firewall rules. + // The name of the firewall policy that this rule is associated with. + // This field is not applicable to VPC firewall rules and implied VPC firewall + // rules. string policy = 9; + // The URI of the firewall policy that this rule is associated with. + // This field is not applicable to VPC firewall rules and implied VPC firewall + // rules. + string policy_uri = 11; + // The firewall rule's type. FirewallRuleType firewall_rule_type = 10; } @@ -428,6 +467,10 @@ message RouteInfo { // Policy based route. POLICY_BASED = 7; + + // Advertised route. Synthetic route which is used to transition from the + // StartFromPrivateNetwork state in Connectivity tests. + ADVERTISED = 101; } // Type of next hop: @@ -502,12 +545,12 @@ message RouteInfo { // Name of a route. string display_name = 1; - // URI of a route. - // Dynamic, peering static and peering dynamic routes do not have an URI. - // Advertised route from Google Cloud VPC to on-premises network also does - // not have an URI. + // URI of a route (if applicable). string uri = 2; + // Region of the route (if applicable). + string region = 19; + // Destination IP range of the route. string dest_ip_range = 3; @@ -540,6 +583,16 @@ message RouteInfo { // URI of a NCC Spoke. NCC_HUB routes only. optional string ncc_spoke_uri = 16; + + // For advertised dynamic routes, the URI of the Cloud Router that advertised + // the corresponding IP prefix. + optional string advertised_route_source_router_uri = 17; + + // For advertised routes, the URI of their next hop, i.e. the URI of the + // hybrid endpoint (VPN tunnel, Interconnect attachment, NCC router appliance) + // the advertised prefix is advertised through, or URI of the source peered + // network. + optional string advertised_route_next_hop_uri = 18; } // For display only. Details of a Google Service sending packets to a @@ -590,16 +643,16 @@ message GoogleServiceInfo { // For display only. Metadata associated with a Compute Engine forwarding rule. message ForwardingRuleInfo { - // Name of a Compute Engine forwarding rule. + // Name of the forwarding rule. string display_name = 1; - // URI of a Compute Engine forwarding rule. + // URI of the forwarding rule. string uri = 2; - // Protocol defined in the forwarding rule that matches the test. + // Protocol defined in the forwarding rule that matches the packet. string matched_protocol = 3; - // Port range defined in the forwarding rule that matches the test. + // Port range defined in the forwarding rule that matches the packet. string matched_port_range = 6; // VIP of the forwarding rule. @@ -608,8 +661,22 @@ message ForwardingRuleInfo { // Target type of the forwarding rule. string target = 5; - // Network URI. Only valid for Internal Load Balancer. + // Network URI. string network_uri = 7; + + // Region of the forwarding rule. Set only for regional forwarding rules. + string region = 8; + + // Name of the load balancer the forwarding rule belongs to. Empty for + // forwarding rules not related to load balancers (like PSC forwarding rules). + string load_balancer_name = 9; + + // URI of the PSC service attachment this forwarding rule targets (if + // applicable). + string psc_service_attachment_uri = 10; + + // PSC Google API target this forwarding rule targets (if applicable). + string psc_google_api_target = 11; } // For display only. Metadata associated with a load balancer. @@ -827,7 +894,7 @@ message DeliverInfo { // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-services). PSC_PUBLISHED_SERVICE = 6; - // Target is all Google APIs that use [Private Service + // Target is Google APIs that use [Private Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis). PSC_GOOGLE_API = 7; @@ -852,6 +919,15 @@ message DeliverInfo { // Target is a Cloud Run revision. Used only for return traces. CLOUD_RUN_REVISION = 14; + + // Target is a Google-managed service. Used only for return traces. + GOOGLE_MANAGED_SERVICE = 15; + + // Target is a Redis Instance. + REDIS_INSTANCE = 16; + + // Target is a Redis Cluster. + REDIS_CLUSTER = 17; } // Target type where the packet is delivered to. @@ -862,6 +938,13 @@ message DeliverInfo { // IP address of the target (if applicable). string ip_address = 3 [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Name of the Cloud Storage Bucket the packet is delivered to (if + // applicable). + string storage_bucket = 4; + + // PSC Google API target the packet is delivered to (if applicable). + string psc_google_api_target = 5; } // Details of the final state "forward" and associated resource. @@ -952,6 +1035,10 @@ message AbortInfo { // found. UNKNOWN_IP = 2; + // Aborted because no endpoint with the packet's destination IP is found in + // the Google-managed project. + GOOGLE_MANAGED_SERVICE_UNKNOWN_IP = 32; + // Aborted because the source IP address doesn't belong to any of the // subnets of the source VPC network. SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK = 23; @@ -968,6 +1055,10 @@ message AbortInfo { // endpoint configs required to run the test. PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS = 29; + // Aborted because user lacks permission to access Cloud Router configs + // required to run the test. + PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS = 36; + // Aborted because no valid source or destination endpoint is derived from // the input test request. NO_SOURCE_LOCATION = 5; @@ -1023,6 +1114,13 @@ message AbortInfo { // not supported. SOURCE_PSC_CLOUD_SQL_UNSUPPORTED = 20; + // Aborted because tests with a Redis Cluster as a source are not supported. + SOURCE_REDIS_CLUSTER_UNSUPPORTED = 34; + + // Aborted because tests with a Redis Instance as a source are not + // supported. + SOURCE_REDIS_INSTANCE_UNSUPPORTED = 35; + // Aborted because tests with a forwarding rule as a source are not // supported. SOURCE_FORWARDING_RULE_UNSUPPORTED = 21; @@ -1161,6 +1259,12 @@ message DropInfo { // Packet sent from or to a Cloud SQL instance that is not in running state. CLOUD_SQL_INSTANCE_NOT_RUNNING = 28; + // Packet sent from or to a Redis Instance that is not in running state. + REDIS_INSTANCE_NOT_RUNNING = 68; + + // Packet sent from or to a Redis Cluster that is not in running state. + REDIS_CLUSTER_NOT_RUNNING = 69; + // The type of traffic is blocked and the user cannot configure a firewall // rule to enable it. See [Always blocked // traffic](https://cloud.google.com/vpc/docs/firewalls#blockedtraffic) for @@ -1226,6 +1330,11 @@ message DropInfo { // instance to a destination network. CLOUD_SQL_INSTANCE_NO_ROUTE = 35; + // Packet was dropped because the Cloud SQL instance requires all + // connections to use Cloud SQL connectors and to target the Cloud SQL proxy + // port (3307). + CLOUD_SQL_CONNECTOR_REQUIRED = 63; + // Packet could be dropped because the Cloud Function is not in an active // status. CLOUD_FUNCTION_NOT_ACTIVE = 22; @@ -1237,6 +1346,14 @@ message DropInfo { // state. VPC_CONNECTOR_NOT_RUNNING = 24; + // Packet could be dropped because the traffic from the serverless service + // to the VPC connector is not allowed. + VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED = 60; + + // Packet could be dropped because the health check traffic to the VPC + // connector is not allowed. + VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED = 61; + // Packet could be dropped because it was sent from a different region // to a regional forwarding without global access. FORWARDING_RULE_REGION_MISMATCH = 25; @@ -1268,6 +1385,10 @@ message DropInfo { // No NAT subnets are defined for the PSC service attachment. NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT = 57; + // PSC endpoint is accessed via NCC, but PSC transitivity configuration is + // not yet propagated. + PSC_TRANSITIVITY_NOT_PROPAGATED = 64; + // The packet sent from the hybrid NEG proxy matches a non-dynamic route, // but such a configuration is not supported. HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED = 55; @@ -1292,6 +1413,75 @@ message DropInfo { // Packet is stuck in a routing loop. ROUTING_LOOP = 59; + + // Packet is dropped inside a Google-managed service due to being delivered + // in return trace to an endpoint that doesn't match the endpoint the packet + // was sent from in forward trace. Used only for return traces. + DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE = 62; + + // Packet is dropped due to a load balancer backend instance not having a + // network interface in the network expected by the load balancer. + LOAD_BALANCER_BACKEND_INVALID_NETWORK = 65; + + // Packet is dropped due to a backend service named port not being defined + // on the instance group level. + BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED = 66; + + // Packet is dropped due to a destination IP range being part of a Private + // NAT IP range. + DESTINATION_IS_PRIVATE_NAT_IP_RANGE = 67; + + // Generic drop cause for a packet being dropped inside a Redis Instance + // service project. + DROPPED_INSIDE_REDIS_INSTANCE_SERVICE = 70; + + // Packet is dropped due to an unsupported port being used to connect to a + // Redis Instance. Port 6379 should be used to connect to a Redis Instance. + REDIS_INSTANCE_UNSUPPORTED_PORT = 71; + + // Packet is dropped due to connecting from PUPI address to a PSA based + // Redis Instance. + REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS = 72; + + // Packet is dropped due to no route to the destination network. + REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK = 73; + + // Redis Instance does not have an external IP address. + REDIS_INSTANCE_NO_EXTERNAL_IP = 74; + + // Packet is dropped due to an unsupported protocol being used to connect to + // a Redis Instance. Only TCP connections are accepted by a Redis Instance. + REDIS_INSTANCE_UNSUPPORTED_PROTOCOL = 78; + + // Generic drop cause for a packet being dropped inside a Redis Cluster + // service project. + DROPPED_INSIDE_REDIS_CLUSTER_SERVICE = 75; + + // Packet is dropped due to an unsupported port being used to connect to a + // Redis Cluster. Ports 6379 and 11000 to 13047 should be used to connect to + // a Redis Cluster. + REDIS_CLUSTER_UNSUPPORTED_PORT = 76; + + // Redis Cluster does not have an external IP address. + REDIS_CLUSTER_NO_EXTERNAL_IP = 77; + + // Packet is dropped due to an unsupported protocol being used to connect to + // a Redis Cluster. Only TCP connections are accepted by a Redis Cluster. + REDIS_CLUSTER_UNSUPPORTED_PROTOCOL = 79; + + // Packet from the non-GCP (on-prem) or unknown GCP network is dropped due + // to the destination IP address not belonging to any IP prefix advertised + // via BGP by the Cloud Router. + NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION = 80; + + // Packet from the non-GCP (on-prem) or unknown GCP network is dropped due + // to the destination IP address not belonging to any IP prefix included to + // the local traffic selector of the VPN tunnel. + NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION = 81; + + // Packet from the unknown peered network is dropped due to no known route + // from the source network to the destination IP address. + NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION = 82; } // Cause that the packet is dropped. @@ -1348,6 +1538,53 @@ message CloudSQLInstanceInfo { string region = 7; } +// For display only. Metadata associated with a Cloud Redis Instance. +message RedisInstanceInfo { + // Name of a Cloud Redis Instance. + string display_name = 1; + + // URI of a Cloud Redis Instance. + string uri = 2; + + // URI of a Cloud Redis Instance network. + string network_uri = 3; + + // Primary endpoint IP address of a Cloud Redis Instance. + string primary_endpoint_ip = 4; + + // Read endpoint IP address of a Cloud Redis Instance (if applicable). + string read_endpoint_ip = 5; + + // Region in which the Cloud Redis Instance is defined. + string region = 6; +} + +// For display only. Metadata associated with a Redis Cluster. +message RedisClusterInfo { + // Name of a Redis Cluster. + string display_name = 1; + + // URI of a Redis Cluster in format + // "projects/{project_id}/locations/{location}/clusters/{cluster_id}" + string uri = 2; + + // URI of a Redis Cluster network in format + // "projects/{project_id}/global/networks/{network_id}". + string network_uri = 3; + + // Discovery endpoint IP address of a Redis Cluster. + string discovery_endpoint_ip_address = 4 + [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Secondary endpoint IP address of a Redis Cluster. + string secondary_endpoint_ip_address = 5 + [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Name of the region in which the Redis Cluster is defined. For example, + // "us-central1". + string location = 6; +} + // For display only. Metadata associated with a Cloud Function. message CloudFunctionInfo { // Name of a Cloud Function. @@ -1619,3 +1856,10 @@ message StorageBucketInfo { // Cloud Storage Bucket name. string bucket = 1; } + +// For display only. Metadata associated with the serverless network endpoint +// group backend. +message ServerlessNegInfo { + // URI of the serverless network endpoint group. + string neg_uri = 1; +} diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/connectivity_test.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/connectivity_test.proto index 3ba30550e1e..f19aa294008 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/connectivity_test.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/connectivity_test.proto @@ -37,9 +37,9 @@ message ConnectivityTest { pattern: "projects/{project}/locations/global/connectivityTests/{test}" }; - // Required. Unique name of the resource using the form: + // Identifier. Unique name of the resource using the form: // `projects/{project_id}/locations/global/connectivityTests/{test}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; // The user-supplied description of the Connectivity Test. // Maximum of 512 characters. @@ -227,6 +227,14 @@ message Endpoint { // A [Cloud SQL](https://cloud.google.com/sql) instance URI. string cloud_sql_instance = 8; + // A [Redis Instance](https://cloud.google.com/memorystore/docs/redis) + // URI. + string redis_instance = 17; + + // A [Redis Cluster](https://cloud.google.com/memorystore/docs/cluster) + // URI. + string redis_cluster = 18; + // A [Cloud Function](https://cloud.google.com/functions). CloudFunctionEndpoint cloud_function = 10; diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/reachability.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/reachability.proto index 8fbb70c4840..d888696545b 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/reachability.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/reachability.proto @@ -103,7 +103,7 @@ service ReachabilityService { // // If the endpoint specifications in `ConnectivityTest` are incomplete, the // reachability result returns a value of `AMBIGUOUS`. See the documentation - // in `ConnectivityTest` for for more details. + // in `ConnectivityTest` for more details. rpc UpdateConnectivityTest(UpdateConnectivityTestRequest) returns (google.longrunning.Operation) { option (google.api.http) = { @@ -157,7 +157,12 @@ service ReachabilityService { message ListConnectivityTestsRequest { // Required. The parent resource of the Connectivity Tests: // `projects/{project_id}/locations/global` - string parent = 1 [(google.api.field_behavior) = REQUIRED]; + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudresourcemanager.googleapis.com/Project" + } + ]; // Number of `ConnectivityTests` to return. int32 page_size = 2; @@ -205,14 +210,24 @@ message ListConnectivityTestsResponse { message GetConnectivityTestRequest { // Required. `ConnectivityTest` resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Request for the `CreateConnectivityTest` method. message CreateConnectivityTestRequest { // Required. The parent resource of the Connectivity Test to create: // `projects/{project_id}/locations/global` - string parent = 1 [(google.api.field_behavior) = REQUIRED]; + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudresourcemanager.googleapis.com/Project" + } + ]; // Required. The logical name of the Connectivity Test in your project // with the following restrictions: @@ -243,14 +258,24 @@ message UpdateConnectivityTestRequest { message DeleteConnectivityTestRequest { // Required. Connectivity Test resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Request for the `RerunConnectivityTest` method. message RerunConnectivityTestRequest { // Required. Connectivity Test resource name using the form: // `projects/{project_id}/locations/global/connectivityTests/{test_id}` - string name = 1 [(google.api.field_behavior) = REQUIRED]; + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkmanagement.googleapis.com/ConnectivityTest" + } + ]; } // Metadata describing an [Operation][google.longrunning.Operation] diff --git a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/trace.proto b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/trace.proto index 33f76c55aa9..8c772c7f0f4 100644 --- a/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/trace.proto +++ b/packages/google-cloud-networkmanagement/protos/google/cloud/networkmanagement/v1beta1/trace.proto @@ -94,6 +94,14 @@ message Step { // A CloudSQLInstanceInfo is populated with starting instance information. START_FROM_CLOUD_SQL_INSTANCE = 22; + // Initial state: packet originating from a Redis instance. + // A RedisInstanceInfo is populated with starting instance information. + START_FROM_REDIS_INSTANCE = 32; + + // Initial state: packet originating from a Redis Cluster. + // A RedisClusterInfo is populated with starting Cluster information. + START_FROM_REDIS_CLUSTER = 33; + // Initial state: packet originating from a Cloud Function. // A CloudFunctionInfo is populated with starting function information. START_FROM_CLOUD_FUNCTION = 23; @@ -115,6 +123,11 @@ message Step { // Private Service Connect. Used only for return traces. START_FROM_PSC_PUBLISHED_SERVICE = 30; + // Initial state: packet originating from a serverless network endpoint + // group backend. Used only for return traces. + // The serverless_neg information is populated. + START_FROM_SERVERLESS_NEG = 31; + // Config checking state: verify ingress firewall rule. APPLY_INGRESS_FIREWALL_RULE = 4; @@ -254,6 +267,12 @@ message Step { // Display information of a Cloud SQL instance. CloudSQLInstanceInfo cloud_sql_instance = 19; + // Display information of a Redis Instance. + RedisInstanceInfo redis_instance = 30; + + // Display information of a Redis Cluster. + RedisClusterInfo redis_cluster = 31; + // Display information of a Cloud Function. CloudFunctionInfo cloud_function = 20; @@ -274,6 +293,10 @@ message Step { // Display information of a Storage Bucket. Used only for return traces. StorageBucketInfo storage_bucket = 28; + + // Display information of a Serverless network endpoint group backend. Used + // only for return traces. + ServerlessNegInfo serverless_neg = 29; } } @@ -302,9 +325,13 @@ message InstanceInfo { // Service account authorized for the instance. string service_account = 8 [deprecated = true]; + + // URI of the PSC network attachment the NIC is attached to (if relevant). + string psc_network_attachment_uri = 9; } // For display only. Metadata associated with a Compute Engine network. +// Next ID: 7 message NetworkInfo { // Name of a Compute Engine network. string display_name = 1; @@ -312,12 +339,18 @@ message NetworkInfo { // URI of a Compute Engine network. string uri = 2; - // The IP range that matches the test. + // URI of the subnet matching the source IP address of the test. + string matched_subnet_uri = 5; + + // The IP range of the subnet matching the source IP address of the test. string matched_ip_range = 4; + + // The region of the subnet matching the source IP address of the test. + string region = 6; } // For display only. Metadata associated with a VPC firewall rule, an implied -// VPC firewall rule, or a hierarchical firewall policy rule. +// VPC firewall rule, or a firewall policy rule. message FirewallInfo { // The firewall rule's type. enum FirewallRuleType { @@ -368,12 +401,12 @@ message FirewallInfo { TRACKING_STATE = 101; } - // The display name of the VPC firewall rule. This field is not applicable - // to hierarchical firewall policy rules. + // The display name of the firewall rule. This field might be empty for + // firewall policy rules. string display_name = 1; - // The URI of the VPC firewall rule. This field is not applicable to - // implied firewall rules or hierarchical firewall policy rules. + // The URI of the firewall rule. This field is not applicable to implied + // VPC firewall rules. string uri = 2; // Possible values: INGRESS, EGRESS @@ -390,16 +423,22 @@ message FirewallInfo { string network_uri = 6; // The target tags defined by the VPC firewall rule. This field is not - // applicable to hierarchical firewall policy rules. + // applicable to firewall policy rules. repeated string target_tags = 7; // The target service accounts specified by the firewall rule. repeated string target_service_accounts = 8; - // The hierarchical firewall policy that this rule is associated with. - // This field is not applicable to VPC firewall rules. + // The name of the firewall policy that this rule is associated with. + // This field is not applicable to VPC firewall rules and implied VPC firewall + // rules. string policy = 9; + // The URI of the firewall policy that this rule is associated with. + // This field is not applicable to VPC firewall rules and implied VPC firewall + // rules. + string policy_uri = 11; + // The firewall rule's type. FirewallRuleType firewall_rule_type = 10; } @@ -432,6 +471,10 @@ message RouteInfo { // Policy based route. POLICY_BASED = 7; + + // Advertised route. Synthetic route which is used to transition from the + // StartFromPrivateNetwork state in Connectivity tests. + ADVERTISED = 101; } // Type of next hop: @@ -506,12 +549,12 @@ message RouteInfo { // Name of a route. string display_name = 1; - // URI of a route. - // Dynamic, peering static and peering dynamic routes do not have an URI. - // Advertised route from Google Cloud VPC to on-premises network also does - // not have an URI. + // URI of a route (if applicable). string uri = 2; + // Region of the route (if applicable). + string region = 19; + // Destination IP range of the route. string dest_ip_range = 3; @@ -544,6 +587,16 @@ message RouteInfo { // URI of a NCC Spoke. NCC_HUB routes only. optional string ncc_spoke_uri = 16; + + // For advertised dynamic routes, the URI of the Cloud Router that advertised + // the corresponding IP prefix. + optional string advertised_route_source_router_uri = 17; + + // For advertised routes, the URI of their next hop, i.e. the URI of the + // hybrid endpoint (VPN tunnel, Interconnect attachment, NCC router appliance) + // the advertised prefix is advertised through, or URI of the source peered + // network. + optional string advertised_route_next_hop_uri = 18; } // For display only. Details of a Google Service sending packets to a @@ -594,16 +647,16 @@ message GoogleServiceInfo { // For display only. Metadata associated with a Compute Engine forwarding rule. message ForwardingRuleInfo { - // Name of a Compute Engine forwarding rule. + // Name of the forwarding rule. string display_name = 1; - // URI of a Compute Engine forwarding rule. + // URI of the forwarding rule. string uri = 2; - // Protocol defined in the forwarding rule that matches the test. + // Protocol defined in the forwarding rule that matches the packet. string matched_protocol = 3; - // Port range defined in the forwarding rule that matches the test. + // Port range defined in the forwarding rule that matches the packet. string matched_port_range = 6; // VIP of the forwarding rule. @@ -612,8 +665,22 @@ message ForwardingRuleInfo { // Target type of the forwarding rule. string target = 5; - // Network URI. Only valid for Internal Load Balancer. + // Network URI. string network_uri = 7; + + // Region of the forwarding rule. Set only for regional forwarding rules. + string region = 8; + + // Name of the load balancer the forwarding rule belongs to. Empty for + // forwarding rules not related to load balancers (like PSC forwarding rules). + string load_balancer_name = 9; + + // URI of the PSC service attachment this forwarding rule targets (if + // applicable). + string psc_service_attachment_uri = 10; + + // PSC Google API target this forwarding rule targets (if applicable). + string psc_google_api_target = 11; } // For display only. Metadata associated with a load balancer. @@ -831,7 +898,7 @@ message DeliverInfo { // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-services). PSC_PUBLISHED_SERVICE = 6; - // Target is all Google APIs that use [Private Service + // Target is Google APIs that use [Private Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis). PSC_GOOGLE_API = 7; @@ -856,6 +923,15 @@ message DeliverInfo { // Target is a Cloud Run revision. Used only for return traces. CLOUD_RUN_REVISION = 14; + + // Target is a Google-managed service. Used only for return traces. + GOOGLE_MANAGED_SERVICE = 15; + + // Target is a Redis Instance. + REDIS_INSTANCE = 16; + + // Target is a Redis Cluster. + REDIS_CLUSTER = 17; } // Target type where the packet is delivered to. @@ -866,6 +942,13 @@ message DeliverInfo { // IP address of the target (if applicable). string ip_address = 3 [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Name of the Cloud Storage Bucket the packet is delivered to (if + // applicable). + string storage_bucket = 4; + + // PSC Google API target the packet is delivered to (if applicable). + string psc_google_api_target = 5; } // Details of the final state "forward" and associated resource. @@ -956,6 +1039,10 @@ message AbortInfo { // found. UNKNOWN_IP = 2; + // Aborted because no endpoint with the packet's destination IP is found in + // the Google-managed project. + GOOGLE_MANAGED_SERVICE_UNKNOWN_IP = 32; + // Aborted because the source IP address doesn't belong to any of the // subnets of the source VPC network. SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK = 23; @@ -972,6 +1059,10 @@ message AbortInfo { // endpoint configs required to run the test. PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS = 29; + // Aborted because user lacks permission to access Cloud Router configs + // required to run the test. + PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS = 36; + // Aborted because no valid source or destination endpoint is derived from // the input test request. NO_SOURCE_LOCATION = 5; @@ -1027,6 +1118,13 @@ message AbortInfo { // not supported. SOURCE_PSC_CLOUD_SQL_UNSUPPORTED = 20; + // Aborted because tests with a Redis Cluster as a source are not supported. + SOURCE_REDIS_CLUSTER_UNSUPPORTED = 34; + + // Aborted because tests with a Redis Instance as a source are not + // supported. + SOURCE_REDIS_INSTANCE_UNSUPPORTED = 35; + // Aborted because tests with a forwarding rule as a source are not // supported. SOURCE_FORWARDING_RULE_UNSUPPORTED = 21; @@ -1165,6 +1263,12 @@ message DropInfo { // Packet sent from or to a Cloud SQL instance that is not in running state. CLOUD_SQL_INSTANCE_NOT_RUNNING = 28; + // Packet sent from or to a Redis Instance that is not in running state. + REDIS_INSTANCE_NOT_RUNNING = 68; + + // Packet sent from or to a Redis Cluster that is not in running state. + REDIS_CLUSTER_NOT_RUNNING = 69; + // The type of traffic is blocked and the user cannot configure a firewall // rule to enable it. See [Always blocked // traffic](https://cloud.google.com/vpc/docs/firewalls#blockedtraffic) for @@ -1230,6 +1334,11 @@ message DropInfo { // instance to a destination network. CLOUD_SQL_INSTANCE_NO_ROUTE = 35; + // Packet was dropped because the Cloud SQL instance requires all + // connections to use Cloud SQL connectors and to target the Cloud SQL proxy + // port (3307). + CLOUD_SQL_CONNECTOR_REQUIRED = 63; + // Packet could be dropped because the Cloud Function is not in an active // status. CLOUD_FUNCTION_NOT_ACTIVE = 22; @@ -1241,6 +1350,14 @@ message DropInfo { // state. VPC_CONNECTOR_NOT_RUNNING = 24; + // Packet could be dropped because the traffic from the serverless service + // to the VPC connector is not allowed. + VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED = 60; + + // Packet could be dropped because the health check traffic to the VPC + // connector is not allowed. + VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED = 61; + // Packet could be dropped because it was sent from a different region // to a regional forwarding without global access. FORWARDING_RULE_REGION_MISMATCH = 25; @@ -1272,6 +1389,10 @@ message DropInfo { // No NAT subnets are defined for the PSC service attachment. NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT = 57; + // PSC endpoint is accessed via NCC, but PSC transitivity configuration is + // not yet propagated. + PSC_TRANSITIVITY_NOT_PROPAGATED = 64; + // The packet sent from the hybrid NEG proxy matches a non-dynamic route, // but such a configuration is not supported. HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED = 55; @@ -1296,6 +1417,75 @@ message DropInfo { // Packet is stuck in a routing loop. ROUTING_LOOP = 59; + + // Packet is dropped inside a Google-managed service due to being delivered + // in return trace to an endpoint that doesn't match the endpoint the packet + // was sent from in forward trace. Used only for return traces. + DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE = 62; + + // Packet is dropped due to a load balancer backend instance not having a + // network interface in the network expected by the load balancer. + LOAD_BALANCER_BACKEND_INVALID_NETWORK = 65; + + // Packet is dropped due to a backend service named port not being defined + // on the instance group level. + BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED = 66; + + // Packet is dropped due to a destination IP range being part of a Private + // NAT IP range. + DESTINATION_IS_PRIVATE_NAT_IP_RANGE = 67; + + // Generic drop cause for a packet being dropped inside a Redis Instance + // service project. + DROPPED_INSIDE_REDIS_INSTANCE_SERVICE = 70; + + // Packet is dropped due to an unsupported port being used to connect to a + // Redis Instance. Port 6379 should be used to connect to a Redis Instance. + REDIS_INSTANCE_UNSUPPORTED_PORT = 71; + + // Packet is dropped due to connecting from PUPI address to a PSA based + // Redis Instance. + REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS = 72; + + // Packet is dropped due to no route to the destination network. + REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK = 73; + + // Redis Instance does not have an external IP address. + REDIS_INSTANCE_NO_EXTERNAL_IP = 74; + + // Packet is dropped due to an unsupported protocol being used to connect to + // a Redis Instance. Only TCP connections are accepted by a Redis Instance. + REDIS_INSTANCE_UNSUPPORTED_PROTOCOL = 78; + + // Generic drop cause for a packet being dropped inside a Redis Cluster + // service project. + DROPPED_INSIDE_REDIS_CLUSTER_SERVICE = 75; + + // Packet is dropped due to an unsupported port being used to connect to a + // Redis Cluster. Ports 6379 and 11000 to 13047 should be used to connect to + // a Redis Cluster. + REDIS_CLUSTER_UNSUPPORTED_PORT = 76; + + // Redis Cluster does not have an external IP address. + REDIS_CLUSTER_NO_EXTERNAL_IP = 77; + + // Packet is dropped due to an unsupported protocol being used to connect to + // a Redis Cluster. Only TCP connections are accepted by a Redis Cluster. + REDIS_CLUSTER_UNSUPPORTED_PROTOCOL = 79; + + // Packet from the non-GCP (on-prem) or unknown GCP network is dropped due + // to the destination IP address not belonging to any IP prefix advertised + // via BGP by the Cloud Router. + NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION = 80; + + // Packet from the non-GCP (on-prem) or unknown GCP network is dropped due + // to the destination IP address not belonging to any IP prefix included to + // the local traffic selector of the VPN tunnel. + NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION = 81; + + // Packet from the unknown peered network is dropped due to no known route + // from the source network to the destination IP address. + NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION = 82; } // Cause that the packet is dropped. @@ -1352,6 +1542,53 @@ message CloudSQLInstanceInfo { string region = 7; } +// For display only. Metadata associated with a Cloud Redis Instance. +message RedisInstanceInfo { + // Name of a Cloud Redis Instance. + string display_name = 1; + + // URI of a Cloud Redis Instance. + string uri = 2; + + // URI of a Cloud Redis Instance network. + string network_uri = 3; + + // Primary endpoint IP address of a Cloud Redis Instance. + string primary_endpoint_ip = 4; + + // Read endpoint IP address of a Cloud Redis Instance (if applicable). + string read_endpoint_ip = 5; + + // Region in which the Cloud Redis Instance is defined. + string region = 6; +} + +// For display only. Metadata associated with a Redis Cluster. +message RedisClusterInfo { + // Name of a Redis Cluster. + string display_name = 1; + + // URI of a Redis Cluster in format + // "projects/{project_id}/locations/{location}/clusters/{cluster_id}" + string uri = 2; + + // URI of a Redis Cluster network in format + // "projects/{project_id}/global/networks/{network_id}". + string network_uri = 3; + + // Discovery endpoint IP address of a Redis Cluster. + string discovery_endpoint_ip_address = 4 + [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Secondary endpoint IP address of a Redis Cluster. + string secondary_endpoint_ip_address = 5 + [(google.api.field_info).format = IPV4_OR_IPV6]; + + // Name of the region in which the Redis Cluster is defined. For example, + // "us-central1". + string location = 6; +} + // For display only. Metadata associated with a Cloud Function. message CloudFunctionInfo { // Name of a Cloud Function. @@ -1623,3 +1860,10 @@ message StorageBucketInfo { // Cloud Storage Bucket name. string bucket = 1; } + +// For display only. Metadata associated with the serverless network endpoint +// group backend. +message ServerlessNegInfo { + // URI of the serverless network endpoint group. + string neg_uri = 1; +} diff --git a/packages/google-cloud-networkmanagement/protos/protos.d.ts b/packages/google-cloud-networkmanagement/protos/protos.d.ts index 30ff9a52b71..9b204e55546 100644 --- a/packages/google-cloud-networkmanagement/protos/protos.d.ts +++ b/packages/google-cloud-networkmanagement/protos/protos.d.ts @@ -225,6 +225,12 @@ export namespace google { /** Endpoint cloudSqlInstance */ cloudSqlInstance?: (string|null); + /** Endpoint redisInstance */ + redisInstance?: (string|null); + + /** Endpoint redisCluster */ + redisCluster?: (string|null); + /** Endpoint cloudFunction */ cloudFunction?: (google.cloud.networkmanagement.v1.Endpoint.ICloudFunctionEndpoint|null); @@ -280,6 +286,12 @@ export namespace google { /** Endpoint cloudSqlInstance. */ public cloudSqlInstance: string; + /** Endpoint redisInstance. */ + public redisInstance: string; + + /** Endpoint redisCluster. */ + public redisCluster: string; + /** Endpoint cloudFunction. */ public cloudFunction?: (google.cloud.networkmanagement.v1.Endpoint.ICloudFunctionEndpoint|null); @@ -1458,6 +1470,12 @@ export namespace google { /** Step cloudSqlInstance */ cloudSqlInstance?: (google.cloud.networkmanagement.v1.ICloudSQLInstanceInfo|null); + /** Step redisInstance */ + redisInstance?: (google.cloud.networkmanagement.v1.IRedisInstanceInfo|null); + + /** Step redisCluster */ + redisCluster?: (google.cloud.networkmanagement.v1.IRedisClusterInfo|null); + /** Step cloudFunction */ cloudFunction?: (google.cloud.networkmanagement.v1.ICloudFunctionInfo|null); @@ -1478,6 +1496,9 @@ export namespace google { /** Step storageBucket */ storageBucket?: (google.cloud.networkmanagement.v1.IStorageBucketInfo|null); + + /** Step serverlessNeg */ + serverlessNeg?: (google.cloud.networkmanagement.v1.IServerlessNegInfo|null); } /** Represents a Step. */ @@ -1552,6 +1573,12 @@ export namespace google { /** Step cloudSqlInstance. */ public cloudSqlInstance?: (google.cloud.networkmanagement.v1.ICloudSQLInstanceInfo|null); + /** Step redisInstance. */ + public redisInstance?: (google.cloud.networkmanagement.v1.IRedisInstanceInfo|null); + + /** Step redisCluster. */ + public redisCluster?: (google.cloud.networkmanagement.v1.IRedisClusterInfo|null); + /** Step cloudFunction. */ public cloudFunction?: (google.cloud.networkmanagement.v1.ICloudFunctionInfo|null); @@ -1573,8 +1600,11 @@ export namespace google { /** Step storageBucket. */ public storageBucket?: (google.cloud.networkmanagement.v1.IStorageBucketInfo|null); + /** Step serverlessNeg. */ + public serverlessNeg?: (google.cloud.networkmanagement.v1.IServerlessNegInfo|null); + /** Step stepInfo. */ - public stepInfo?: ("instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"); + public stepInfo?: ("instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"redisInstance"|"redisCluster"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|"serverlessNeg"); /** * Creates a new Step instance using the specified properties. @@ -1665,11 +1695,14 @@ export namespace google { START_FROM_PRIVATE_NETWORK = 3, START_FROM_GKE_MASTER = 21, START_FROM_CLOUD_SQL_INSTANCE = 22, + START_FROM_REDIS_INSTANCE = 32, + START_FROM_REDIS_CLUSTER = 33, START_FROM_CLOUD_FUNCTION = 23, START_FROM_APP_ENGINE_VERSION = 25, START_FROM_CLOUD_RUN_REVISION = 26, START_FROM_STORAGE_BUCKET = 29, START_FROM_PSC_PUBLISHED_SERVICE = 30, + START_FROM_SERVERLESS_NEG = 31, APPLY_INGRESS_FIREWALL_RULE = 4, APPLY_EGRESS_FIREWALL_RULE = 5, APPLY_ROUTE = 6, @@ -1718,6 +1751,9 @@ export namespace google { /** InstanceInfo serviceAccount */ serviceAccount?: (string|null); + + /** InstanceInfo pscNetworkAttachmentUri */ + pscNetworkAttachmentUri?: (string|null); } /** Represents an InstanceInfo. */ @@ -1753,6 +1789,9 @@ export namespace google { /** InstanceInfo serviceAccount. */ public serviceAccount: string; + /** InstanceInfo pscNetworkAttachmentUri. */ + public pscNetworkAttachmentUri: string; + /** * Creates a new InstanceInfo instance using the specified properties. * @param [properties] Properties to set @@ -1840,8 +1879,14 @@ export namespace google { /** NetworkInfo uri */ uri?: (string|null); + /** NetworkInfo matchedSubnetUri */ + matchedSubnetUri?: (string|null); + /** NetworkInfo matchedIpRange */ matchedIpRange?: (string|null); + + /** NetworkInfo region */ + region?: (string|null); } /** Represents a NetworkInfo. */ @@ -1859,9 +1904,15 @@ export namespace google { /** NetworkInfo uri. */ public uri: string; + /** NetworkInfo matchedSubnetUri. */ + public matchedSubnetUri: string; + /** NetworkInfo matchedIpRange. */ public matchedIpRange: string; + /** NetworkInfo region. */ + public region: string; + /** * Creates a new NetworkInfo instance using the specified properties. * @param [properties] Properties to set @@ -1970,6 +2021,9 @@ export namespace google { /** FirewallInfo policy */ policy?: (string|null); + /** FirewallInfo policyUri */ + policyUri?: (string|null); + /** FirewallInfo firewallRuleType */ firewallRuleType?: (google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType|keyof typeof google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType|null); } @@ -2010,6 +2064,9 @@ export namespace google { /** FirewallInfo policy. */ public policy: string; + /** FirewallInfo policyUri. */ + public policyUri: string; + /** FirewallInfo firewallRuleType. */ public firewallRuleType: (google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType|keyof typeof google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType); @@ -2125,6 +2182,9 @@ export namespace google { /** RouteInfo uri */ uri?: (string|null); + /** RouteInfo region */ + region?: (string|null); + /** RouteInfo destIpRange */ destIpRange?: (string|null); @@ -2157,6 +2217,12 @@ export namespace google { /** RouteInfo nccSpokeUri */ nccSpokeUri?: (string|null); + + /** RouteInfo advertisedRouteSourceRouterUri */ + advertisedRouteSourceRouterUri?: (string|null); + + /** RouteInfo advertisedRouteNextHopUri */ + advertisedRouteNextHopUri?: (string|null); } /** Represents a RouteInfo. */ @@ -2183,6 +2249,9 @@ export namespace google { /** RouteInfo uri. */ public uri: string; + /** RouteInfo region. */ + public region: string; + /** RouteInfo destIpRange. */ public destIpRange: string; @@ -2216,12 +2285,24 @@ export namespace google { /** RouteInfo nccSpokeUri. */ public nccSpokeUri?: (string|null); + /** RouteInfo advertisedRouteSourceRouterUri. */ + public advertisedRouteSourceRouterUri?: (string|null); + + /** RouteInfo advertisedRouteNextHopUri. */ + public advertisedRouteNextHopUri?: (string|null); + /** RouteInfo _nccHubUri. */ public _nccHubUri?: "nccHubUri"; /** RouteInfo _nccSpokeUri. */ public _nccSpokeUri?: "nccSpokeUri"; + /** RouteInfo _advertisedRouteSourceRouterUri. */ + public _advertisedRouteSourceRouterUri?: "advertisedRouteSourceRouterUri"; + + /** RouteInfo _advertisedRouteNextHopUri. */ + public _advertisedRouteNextHopUri?: "advertisedRouteNextHopUri"; + /** * Creates a new RouteInfo instance using the specified properties. * @param [properties] Properties to set @@ -2311,7 +2392,8 @@ export namespace google { PEERING_SUBNET = 4, PEERING_STATIC = 5, PEERING_DYNAMIC = 6, - POLICY_BASED = 7 + POLICY_BASED = 7, + ADVERTISED = 101 } /** NextHopType enum. */ @@ -2479,6 +2561,18 @@ export namespace google { /** ForwardingRuleInfo networkUri */ networkUri?: (string|null); + + /** ForwardingRuleInfo region */ + region?: (string|null); + + /** ForwardingRuleInfo loadBalancerName */ + loadBalancerName?: (string|null); + + /** ForwardingRuleInfo pscServiceAttachmentUri */ + pscServiceAttachmentUri?: (string|null); + + /** ForwardingRuleInfo pscGoogleApiTarget */ + pscGoogleApiTarget?: (string|null); } /** Represents a ForwardingRuleInfo. */ @@ -2511,6 +2605,18 @@ export namespace google { /** ForwardingRuleInfo networkUri. */ public networkUri: string; + /** ForwardingRuleInfo region. */ + public region: string; + + /** ForwardingRuleInfo loadBalancerName. */ + public loadBalancerName: string; + + /** ForwardingRuleInfo pscServiceAttachmentUri. */ + public pscServiceAttachmentUri: string; + + /** ForwardingRuleInfo pscGoogleApiTarget. */ + public pscGoogleApiTarget: string; + /** * Creates a new ForwardingRuleInfo instance using the specified properties. * @param [properties] Properties to set @@ -3295,6 +3401,12 @@ export namespace google { /** DeliverInfo ipAddress */ ipAddress?: (string|null); + + /** DeliverInfo storageBucket */ + storageBucket?: (string|null); + + /** DeliverInfo pscGoogleApiTarget */ + pscGoogleApiTarget?: (string|null); } /** Represents a DeliverInfo. */ @@ -3315,6 +3427,12 @@ export namespace google { /** DeliverInfo ipAddress. */ public ipAddress: string; + /** DeliverInfo storageBucket. */ + public storageBucket: string; + + /** DeliverInfo pscGoogleApiTarget. */ + public pscGoogleApiTarget: string; + /** * Creates a new DeliverInfo instance using the specified properties. * @param [properties] Properties to set @@ -3411,7 +3529,10 @@ export namespace google { PRIVATE_NETWORK = 11, CLOUD_FUNCTION = 12, APP_ENGINE_VERSION = 13, - CLOUD_RUN_REVISION = 14 + CLOUD_RUN_REVISION = 14, + GOOGLE_MANAGED_SERVICE = 15, + REDIS_INSTANCE = 16, + REDIS_CLUSTER = 17 } } @@ -3670,10 +3791,12 @@ export namespace google { DESTINATION_ENDPOINT_NOT_FOUND = 13, MISMATCHED_DESTINATION_NETWORK = 14, UNKNOWN_IP = 2, + GOOGLE_MANAGED_SERVICE_UNKNOWN_IP = 32, SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK = 23, PERMISSION_DENIED = 4, PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS = 28, PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS = 29, + PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS = 36, NO_SOURCE_LOCATION = 5, INVALID_ARGUMENT = 6, TRACE_TOO_LONG = 9, @@ -3688,6 +3811,8 @@ export namespace google { ROUTE_CONFIG_NOT_FOUND = 27, GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT = 19, SOURCE_PSC_CLOUD_SQL_UNSUPPORTED = 20, + SOURCE_REDIS_CLUSTER_UNSUPPORTED = 34, + SOURCE_REDIS_INSTANCE_UNSUPPORTED = 35, SOURCE_FORWARDING_RULE_UNSUPPORTED = 21, NON_ROUTABLE_IP_ADDRESS = 22, UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT = 30, @@ -3848,6 +3973,8 @@ export namespace google { INSTANCE_NOT_RUNNING = 14, GKE_CLUSTER_NOT_RUNNING = 27, CLOUD_SQL_INSTANCE_NOT_RUNNING = 28, + REDIS_INSTANCE_NOT_RUNNING = 68, + REDIS_CLUSTER_NOT_RUNNING = 69, TRAFFIC_TYPE_BLOCKED = 15, GKE_MASTER_UNAUTHORIZED_ACCESS = 16, CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS = 17, @@ -3863,9 +3990,12 @@ export namespace google { CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC = 33, PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION = 34, CLOUD_SQL_INSTANCE_NO_ROUTE = 35, + CLOUD_SQL_CONNECTOR_REQUIRED = 63, CLOUD_FUNCTION_NOT_ACTIVE = 22, VPC_CONNECTOR_NOT_SET = 23, VPC_CONNECTOR_NOT_RUNNING = 24, + VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED = 60, + VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED = 61, FORWARDING_RULE_REGION_MISMATCH = 25, PSC_CONNECTION_NOT_ACCEPTED = 26, PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK = 41, @@ -3873,13 +4003,31 @@ export namespace google { PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS = 54, CLOUD_SQL_PSC_NEG_UNSUPPORTED = 58, NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT = 57, + PSC_TRANSITIVITY_NOT_PROPAGATED = 64, HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED = 55, HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED = 56, CLOUD_RUN_REVISION_NOT_READY = 29, DROPPED_INSIDE_PSC_SERVICE_PRODUCER = 37, LOAD_BALANCER_HAS_NO_PROXY_SUBNET = 39, CLOUD_NAT_NO_ADDRESSES = 40, - ROUTING_LOOP = 59 + ROUTING_LOOP = 59, + DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE = 62, + LOAD_BALANCER_BACKEND_INVALID_NETWORK = 65, + BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED = 66, + DESTINATION_IS_PRIVATE_NAT_IP_RANGE = 67, + DROPPED_INSIDE_REDIS_INSTANCE_SERVICE = 70, + REDIS_INSTANCE_UNSUPPORTED_PORT = 71, + REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS = 72, + REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK = 73, + REDIS_INSTANCE_NO_EXTERNAL_IP = 74, + REDIS_INSTANCE_UNSUPPORTED_PROTOCOL = 78, + DROPPED_INSIDE_REDIS_CLUSTER_SERVICE = 75, + REDIS_CLUSTER_UNSUPPORTED_PORT = 76, + REDIS_CLUSTER_NO_EXTERNAL_IP = 77, + REDIS_CLUSTER_UNSUPPORTED_PROTOCOL = 79, + NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION = 80, + NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION = 81, + NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION = 82 } } @@ -4125,6 +4273,260 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } + /** Properties of a RedisInstanceInfo. */ + interface IRedisInstanceInfo { + + /** RedisInstanceInfo displayName */ + displayName?: (string|null); + + /** RedisInstanceInfo uri */ + uri?: (string|null); + + /** RedisInstanceInfo networkUri */ + networkUri?: (string|null); + + /** RedisInstanceInfo primaryEndpointIp */ + primaryEndpointIp?: (string|null); + + /** RedisInstanceInfo readEndpointIp */ + readEndpointIp?: (string|null); + + /** RedisInstanceInfo region */ + region?: (string|null); + } + + /** Represents a RedisInstanceInfo. */ + class RedisInstanceInfo implements IRedisInstanceInfo { + + /** + * Constructs a new RedisInstanceInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.networkmanagement.v1.IRedisInstanceInfo); + + /** RedisInstanceInfo displayName. */ + public displayName: string; + + /** RedisInstanceInfo uri. */ + public uri: string; + + /** RedisInstanceInfo networkUri. */ + public networkUri: string; + + /** RedisInstanceInfo primaryEndpointIp. */ + public primaryEndpointIp: string; + + /** RedisInstanceInfo readEndpointIp. */ + public readEndpointIp: string; + + /** RedisInstanceInfo region. */ + public region: string; + + /** + * Creates a new RedisInstanceInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns RedisInstanceInfo instance + */ + public static create(properties?: google.cloud.networkmanagement.v1.IRedisInstanceInfo): google.cloud.networkmanagement.v1.RedisInstanceInfo; + + /** + * Encodes the specified RedisInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisInstanceInfo.verify|verify} messages. + * @param message RedisInstanceInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.networkmanagement.v1.IRedisInstanceInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified RedisInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisInstanceInfo.verify|verify} messages. + * @param message RedisInstanceInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.networkmanagement.v1.IRedisInstanceInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a RedisInstanceInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns RedisInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1.RedisInstanceInfo; + + /** + * Decodes a RedisInstanceInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns RedisInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1.RedisInstanceInfo; + + /** + * Verifies a RedisInstanceInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a RedisInstanceInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns RedisInstanceInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1.RedisInstanceInfo; + + /** + * Creates a plain object from a RedisInstanceInfo message. Also converts values to other types if specified. + * @param message RedisInstanceInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1.RedisInstanceInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this RedisInstanceInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for RedisInstanceInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a RedisClusterInfo. */ + interface IRedisClusterInfo { + + /** RedisClusterInfo displayName */ + displayName?: (string|null); + + /** RedisClusterInfo uri */ + uri?: (string|null); + + /** RedisClusterInfo networkUri */ + networkUri?: (string|null); + + /** RedisClusterInfo discoveryEndpointIpAddress */ + discoveryEndpointIpAddress?: (string|null); + + /** RedisClusterInfo secondaryEndpointIpAddress */ + secondaryEndpointIpAddress?: (string|null); + + /** RedisClusterInfo location */ + location?: (string|null); + } + + /** Represents a RedisClusterInfo. */ + class RedisClusterInfo implements IRedisClusterInfo { + + /** + * Constructs a new RedisClusterInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.networkmanagement.v1.IRedisClusterInfo); + + /** RedisClusterInfo displayName. */ + public displayName: string; + + /** RedisClusterInfo uri. */ + public uri: string; + + /** RedisClusterInfo networkUri. */ + public networkUri: string; + + /** RedisClusterInfo discoveryEndpointIpAddress. */ + public discoveryEndpointIpAddress: string; + + /** RedisClusterInfo secondaryEndpointIpAddress. */ + public secondaryEndpointIpAddress: string; + + /** RedisClusterInfo location. */ + public location: string; + + /** + * Creates a new RedisClusterInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns RedisClusterInfo instance + */ + public static create(properties?: google.cloud.networkmanagement.v1.IRedisClusterInfo): google.cloud.networkmanagement.v1.RedisClusterInfo; + + /** + * Encodes the specified RedisClusterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisClusterInfo.verify|verify} messages. + * @param message RedisClusterInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.networkmanagement.v1.IRedisClusterInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified RedisClusterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisClusterInfo.verify|verify} messages. + * @param message RedisClusterInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.networkmanagement.v1.IRedisClusterInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a RedisClusterInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns RedisClusterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1.RedisClusterInfo; + + /** + * Decodes a RedisClusterInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns RedisClusterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1.RedisClusterInfo; + + /** + * Verifies a RedisClusterInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a RedisClusterInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns RedisClusterInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1.RedisClusterInfo; + + /** + * Creates a plain object from a RedisClusterInfo message. Also converts values to other types if specified. + * @param message RedisClusterInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1.RedisClusterInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this RedisClusterInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for RedisClusterInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + /** Properties of a CloudFunctionInfo. */ interface ICloudFunctionInfo { @@ -5192,53 +5594,150 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Represents a ReachabilityService */ - class ReachabilityService extends $protobuf.rpc.Service { + /** Properties of a ServerlessNegInfo. */ + interface IServerlessNegInfo { - /** - * Constructs a new ReachabilityService service. - * @param rpcImpl RPC implementation - * @param [requestDelimited=false] Whether requests are length-delimited - * @param [responseDelimited=false] Whether responses are length-delimited - */ - constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean); + /** ServerlessNegInfo negUri */ + negUri?: (string|null); + } + + /** Represents a ServerlessNegInfo. */ + class ServerlessNegInfo implements IServerlessNegInfo { /** - * Creates new ReachabilityService service using the specified rpc implementation. - * @param rpcImpl RPC implementation - * @param [requestDelimited=false] Whether requests are length-delimited - * @param [responseDelimited=false] Whether responses are length-delimited - * @returns RPC service. Useful where requests and/or responses are streamed. + * Constructs a new ServerlessNegInfo. + * @param [properties] Properties to set */ - public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): ReachabilityService; + constructor(properties?: google.cloud.networkmanagement.v1.IServerlessNegInfo); + + /** ServerlessNegInfo negUri. */ + public negUri: string; /** - * Calls ListConnectivityTests. - * @param request ListConnectivityTestsRequest message or plain object - * @param callback Node-style callback called with the error, if any, and ListConnectivityTestsResponse + * Creates a new ServerlessNegInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns ServerlessNegInfo instance */ - public listConnectivityTests(request: google.cloud.networkmanagement.v1.IListConnectivityTestsRequest, callback: google.cloud.networkmanagement.v1.ReachabilityService.ListConnectivityTestsCallback): void; + public static create(properties?: google.cloud.networkmanagement.v1.IServerlessNegInfo): google.cloud.networkmanagement.v1.ServerlessNegInfo; /** - * Calls ListConnectivityTests. - * @param request ListConnectivityTestsRequest message or plain object - * @returns Promise + * Encodes the specified ServerlessNegInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.ServerlessNegInfo.verify|verify} messages. + * @param message ServerlessNegInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer */ - public listConnectivityTests(request: google.cloud.networkmanagement.v1.IListConnectivityTestsRequest): Promise; + public static encode(message: google.cloud.networkmanagement.v1.IServerlessNegInfo, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Calls GetConnectivityTest. - * @param request GetConnectivityTestRequest message or plain object - * @param callback Node-style callback called with the error, if any, and ConnectivityTest + * Encodes the specified ServerlessNegInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ServerlessNegInfo.verify|verify} messages. + * @param message ServerlessNegInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer */ - public getConnectivityTest(request: google.cloud.networkmanagement.v1.IGetConnectivityTestRequest, callback: google.cloud.networkmanagement.v1.ReachabilityService.GetConnectivityTestCallback): void; + public static encodeDelimited(message: google.cloud.networkmanagement.v1.IServerlessNegInfo, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Calls GetConnectivityTest. - * @param request GetConnectivityTestRequest message or plain object - * @returns Promise + * Decodes a ServerlessNegInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public getConnectivityTest(request: google.cloud.networkmanagement.v1.IGetConnectivityTestRequest): Promise; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1.ServerlessNegInfo; + + /** + * Decodes a ServerlessNegInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1.ServerlessNegInfo; + + /** + * Verifies a ServerlessNegInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ServerlessNegInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ServerlessNegInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1.ServerlessNegInfo; + + /** + * Creates a plain object from a ServerlessNegInfo message. Also converts values to other types if specified. + * @param message ServerlessNegInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1.ServerlessNegInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ServerlessNegInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ServerlessNegInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Represents a ReachabilityService */ + class ReachabilityService extends $protobuf.rpc.Service { + + /** + * Constructs a new ReachabilityService service. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + */ + constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean); + + /** + * Creates new ReachabilityService service using the specified rpc implementation. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + * @returns RPC service. Useful where requests and/or responses are streamed. + */ + public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): ReachabilityService; + + /** + * Calls ListConnectivityTests. + * @param request ListConnectivityTestsRequest message or plain object + * @param callback Node-style callback called with the error, if any, and ListConnectivityTestsResponse + */ + public listConnectivityTests(request: google.cloud.networkmanagement.v1.IListConnectivityTestsRequest, callback: google.cloud.networkmanagement.v1.ReachabilityService.ListConnectivityTestsCallback): void; + + /** + * Calls ListConnectivityTests. + * @param request ListConnectivityTestsRequest message or plain object + * @returns Promise + */ + public listConnectivityTests(request: google.cloud.networkmanagement.v1.IListConnectivityTestsRequest): Promise; + + /** + * Calls GetConnectivityTest. + * @param request GetConnectivityTestRequest message or plain object + * @param callback Node-style callback called with the error, if any, and ConnectivityTest + */ + public getConnectivityTest(request: google.cloud.networkmanagement.v1.IGetConnectivityTestRequest, callback: google.cloud.networkmanagement.v1.ReachabilityService.GetConnectivityTestCallback): void; + + /** + * Calls GetConnectivityTest. + * @param request GetConnectivityTestRequest message or plain object + * @returns Promise + */ + public getConnectivityTest(request: google.cloud.networkmanagement.v1.IGetConnectivityTestRequest): Promise; /** * Calls CreateConnectivityTest. @@ -6411,6 +6910,12 @@ export namespace google { /** Endpoint cloudSqlInstance */ cloudSqlInstance?: (string|null); + /** Endpoint redisInstance */ + redisInstance?: (string|null); + + /** Endpoint redisCluster */ + redisCluster?: (string|null); + /** Endpoint cloudFunction */ cloudFunction?: (google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null); @@ -6466,6 +6971,12 @@ export namespace google { /** Endpoint cloudSqlInstance. */ public cloudSqlInstance: string; + /** Endpoint redisInstance. */ + public redisInstance: string; + + /** Endpoint redisCluster. */ + public redisCluster: string; + /** Endpoint cloudFunction. */ public cloudFunction?: (google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null); @@ -7644,6 +8155,12 @@ export namespace google { /** Step cloudSqlInstance */ cloudSqlInstance?: (google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null); + /** Step redisInstance */ + redisInstance?: (google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo|null); + + /** Step redisCluster */ + redisCluster?: (google.cloud.networkmanagement.v1beta1.IRedisClusterInfo|null); + /** Step cloudFunction */ cloudFunction?: (google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null); @@ -7664,6 +8181,9 @@ export namespace google { /** Step storageBucket */ storageBucket?: (google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null); + + /** Step serverlessNeg */ + serverlessNeg?: (google.cloud.networkmanagement.v1beta1.IServerlessNegInfo|null); } /** Represents a Step. */ @@ -7738,6 +8258,12 @@ export namespace google { /** Step cloudSqlInstance. */ public cloudSqlInstance?: (google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null); + /** Step redisInstance. */ + public redisInstance?: (google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo|null); + + /** Step redisCluster. */ + public redisCluster?: (google.cloud.networkmanagement.v1beta1.IRedisClusterInfo|null); + /** Step cloudFunction. */ public cloudFunction?: (google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null); @@ -7759,8 +8285,11 @@ export namespace google { /** Step storageBucket. */ public storageBucket?: (google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null); + /** Step serverlessNeg. */ + public serverlessNeg?: (google.cloud.networkmanagement.v1beta1.IServerlessNegInfo|null); + /** Step stepInfo. */ - public stepInfo?: ("instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"); + public stepInfo?: ("instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"redisInstance"|"redisCluster"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|"serverlessNeg"); /** * Creates a new Step instance using the specified properties. @@ -7851,11 +8380,14 @@ export namespace google { START_FROM_PRIVATE_NETWORK = 3, START_FROM_GKE_MASTER = 21, START_FROM_CLOUD_SQL_INSTANCE = 22, + START_FROM_REDIS_INSTANCE = 32, + START_FROM_REDIS_CLUSTER = 33, START_FROM_CLOUD_FUNCTION = 23, START_FROM_APP_ENGINE_VERSION = 25, START_FROM_CLOUD_RUN_REVISION = 26, START_FROM_STORAGE_BUCKET = 29, START_FROM_PSC_PUBLISHED_SERVICE = 30, + START_FROM_SERVERLESS_NEG = 31, APPLY_INGRESS_FIREWALL_RULE = 4, APPLY_EGRESS_FIREWALL_RULE = 5, APPLY_ROUTE = 6, @@ -7904,6 +8436,9 @@ export namespace google { /** InstanceInfo serviceAccount */ serviceAccount?: (string|null); + + /** InstanceInfo pscNetworkAttachmentUri */ + pscNetworkAttachmentUri?: (string|null); } /** Represents an InstanceInfo. */ @@ -7939,6 +8474,9 @@ export namespace google { /** InstanceInfo serviceAccount. */ public serviceAccount: string; + /** InstanceInfo pscNetworkAttachmentUri. */ + public pscNetworkAttachmentUri: string; + /** * Creates a new InstanceInfo instance using the specified properties. * @param [properties] Properties to set @@ -8026,8 +8564,14 @@ export namespace google { /** NetworkInfo uri */ uri?: (string|null); + /** NetworkInfo matchedSubnetUri */ + matchedSubnetUri?: (string|null); + /** NetworkInfo matchedIpRange */ matchedIpRange?: (string|null); + + /** NetworkInfo region */ + region?: (string|null); } /** Represents a NetworkInfo. */ @@ -8045,9 +8589,15 @@ export namespace google { /** NetworkInfo uri. */ public uri: string; + /** NetworkInfo matchedSubnetUri. */ + public matchedSubnetUri: string; + /** NetworkInfo matchedIpRange. */ public matchedIpRange: string; + /** NetworkInfo region. */ + public region: string; + /** * Creates a new NetworkInfo instance using the specified properties. * @param [properties] Properties to set @@ -8156,6 +8706,9 @@ export namespace google { /** FirewallInfo policy */ policy?: (string|null); + /** FirewallInfo policyUri */ + policyUri?: (string|null); + /** FirewallInfo firewallRuleType */ firewallRuleType?: (google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType|keyof typeof google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType|null); } @@ -8196,6 +8749,9 @@ export namespace google { /** FirewallInfo policy. */ public policy: string; + /** FirewallInfo policyUri. */ + public policyUri: string; + /** FirewallInfo firewallRuleType. */ public firewallRuleType: (google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType|keyof typeof google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType); @@ -8311,6 +8867,9 @@ export namespace google { /** RouteInfo uri */ uri?: (string|null); + /** RouteInfo region */ + region?: (string|null); + /** RouteInfo destIpRange */ destIpRange?: (string|null); @@ -8343,6 +8902,12 @@ export namespace google { /** RouteInfo nccSpokeUri */ nccSpokeUri?: (string|null); + + /** RouteInfo advertisedRouteSourceRouterUri */ + advertisedRouteSourceRouterUri?: (string|null); + + /** RouteInfo advertisedRouteNextHopUri */ + advertisedRouteNextHopUri?: (string|null); } /** Represents a RouteInfo. */ @@ -8369,6 +8934,9 @@ export namespace google { /** RouteInfo uri. */ public uri: string; + /** RouteInfo region. */ + public region: string; + /** RouteInfo destIpRange. */ public destIpRange: string; @@ -8402,12 +8970,24 @@ export namespace google { /** RouteInfo nccSpokeUri. */ public nccSpokeUri?: (string|null); + /** RouteInfo advertisedRouteSourceRouterUri. */ + public advertisedRouteSourceRouterUri?: (string|null); + + /** RouteInfo advertisedRouteNextHopUri. */ + public advertisedRouteNextHopUri?: (string|null); + /** RouteInfo _nccHubUri. */ public _nccHubUri?: "nccHubUri"; /** RouteInfo _nccSpokeUri. */ public _nccSpokeUri?: "nccSpokeUri"; + /** RouteInfo _advertisedRouteSourceRouterUri. */ + public _advertisedRouteSourceRouterUri?: "advertisedRouteSourceRouterUri"; + + /** RouteInfo _advertisedRouteNextHopUri. */ + public _advertisedRouteNextHopUri?: "advertisedRouteNextHopUri"; + /** * Creates a new RouteInfo instance using the specified properties. * @param [properties] Properties to set @@ -8497,7 +9077,8 @@ export namespace google { PEERING_SUBNET = 4, PEERING_STATIC = 5, PEERING_DYNAMIC = 6, - POLICY_BASED = 7 + POLICY_BASED = 7, + ADVERTISED = 101 } /** NextHopType enum. */ @@ -8665,6 +9246,18 @@ export namespace google { /** ForwardingRuleInfo networkUri */ networkUri?: (string|null); + + /** ForwardingRuleInfo region */ + region?: (string|null); + + /** ForwardingRuleInfo loadBalancerName */ + loadBalancerName?: (string|null); + + /** ForwardingRuleInfo pscServiceAttachmentUri */ + pscServiceAttachmentUri?: (string|null); + + /** ForwardingRuleInfo pscGoogleApiTarget */ + pscGoogleApiTarget?: (string|null); } /** Represents a ForwardingRuleInfo. */ @@ -8697,6 +9290,18 @@ export namespace google { /** ForwardingRuleInfo networkUri. */ public networkUri: string; + /** ForwardingRuleInfo region. */ + public region: string; + + /** ForwardingRuleInfo loadBalancerName. */ + public loadBalancerName: string; + + /** ForwardingRuleInfo pscServiceAttachmentUri. */ + public pscServiceAttachmentUri: string; + + /** ForwardingRuleInfo pscGoogleApiTarget. */ + public pscGoogleApiTarget: string; + /** * Creates a new ForwardingRuleInfo instance using the specified properties. * @param [properties] Properties to set @@ -9481,6 +10086,12 @@ export namespace google { /** DeliverInfo ipAddress */ ipAddress?: (string|null); + + /** DeliverInfo storageBucket */ + storageBucket?: (string|null); + + /** DeliverInfo pscGoogleApiTarget */ + pscGoogleApiTarget?: (string|null); } /** Represents a DeliverInfo. */ @@ -9501,6 +10112,12 @@ export namespace google { /** DeliverInfo ipAddress. */ public ipAddress: string; + /** DeliverInfo storageBucket. */ + public storageBucket: string; + + /** DeliverInfo pscGoogleApiTarget. */ + public pscGoogleApiTarget: string; + /** * Creates a new DeliverInfo instance using the specified properties. * @param [properties] Properties to set @@ -9597,7 +10214,10 @@ export namespace google { PRIVATE_NETWORK = 11, CLOUD_FUNCTION = 12, APP_ENGINE_VERSION = 13, - CLOUD_RUN_REVISION = 14 + CLOUD_RUN_REVISION = 14, + GOOGLE_MANAGED_SERVICE = 15, + REDIS_INSTANCE = 16, + REDIS_CLUSTER = 17 } } @@ -9856,10 +10476,12 @@ export namespace google { DESTINATION_ENDPOINT_NOT_FOUND = 13, MISMATCHED_DESTINATION_NETWORK = 14, UNKNOWN_IP = 2, + GOOGLE_MANAGED_SERVICE_UNKNOWN_IP = 32, SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK = 23, PERMISSION_DENIED = 4, PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS = 28, PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS = 29, + PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS = 36, NO_SOURCE_LOCATION = 5, INVALID_ARGUMENT = 6, TRACE_TOO_LONG = 9, @@ -9874,6 +10496,8 @@ export namespace google { ROUTE_CONFIG_NOT_FOUND = 27, GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT = 19, SOURCE_PSC_CLOUD_SQL_UNSUPPORTED = 20, + SOURCE_REDIS_CLUSTER_UNSUPPORTED = 34, + SOURCE_REDIS_INSTANCE_UNSUPPORTED = 35, SOURCE_FORWARDING_RULE_UNSUPPORTED = 21, NON_ROUTABLE_IP_ADDRESS = 22, UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT = 30, @@ -10034,6 +10658,8 @@ export namespace google { INSTANCE_NOT_RUNNING = 14, GKE_CLUSTER_NOT_RUNNING = 27, CLOUD_SQL_INSTANCE_NOT_RUNNING = 28, + REDIS_INSTANCE_NOT_RUNNING = 68, + REDIS_CLUSTER_NOT_RUNNING = 69, TRAFFIC_TYPE_BLOCKED = 15, GKE_MASTER_UNAUTHORIZED_ACCESS = 16, CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS = 17, @@ -10049,9 +10675,12 @@ export namespace google { CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC = 33, PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION = 34, CLOUD_SQL_INSTANCE_NO_ROUTE = 35, + CLOUD_SQL_CONNECTOR_REQUIRED = 63, CLOUD_FUNCTION_NOT_ACTIVE = 22, VPC_CONNECTOR_NOT_SET = 23, VPC_CONNECTOR_NOT_RUNNING = 24, + VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED = 60, + VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED = 61, FORWARDING_RULE_REGION_MISMATCH = 25, PSC_CONNECTION_NOT_ACCEPTED = 26, PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK = 41, @@ -10059,13 +10688,31 @@ export namespace google { PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS = 54, CLOUD_SQL_PSC_NEG_UNSUPPORTED = 58, NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT = 57, + PSC_TRANSITIVITY_NOT_PROPAGATED = 64, HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED = 55, HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED = 56, CLOUD_RUN_REVISION_NOT_READY = 29, DROPPED_INSIDE_PSC_SERVICE_PRODUCER = 37, LOAD_BALANCER_HAS_NO_PROXY_SUBNET = 39, CLOUD_NAT_NO_ADDRESSES = 40, - ROUTING_LOOP = 59 + ROUTING_LOOP = 59, + DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE = 62, + LOAD_BALANCER_BACKEND_INVALID_NETWORK = 65, + BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED = 66, + DESTINATION_IS_PRIVATE_NAT_IP_RANGE = 67, + DROPPED_INSIDE_REDIS_INSTANCE_SERVICE = 70, + REDIS_INSTANCE_UNSUPPORTED_PORT = 71, + REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS = 72, + REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK = 73, + REDIS_INSTANCE_NO_EXTERNAL_IP = 74, + REDIS_INSTANCE_UNSUPPORTED_PROTOCOL = 78, + DROPPED_INSIDE_REDIS_CLUSTER_SERVICE = 75, + REDIS_CLUSTER_UNSUPPORTED_PORT = 76, + REDIS_CLUSTER_NO_EXTERNAL_IP = 77, + REDIS_CLUSTER_UNSUPPORTED_PROTOCOL = 79, + NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION = 80, + NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION = 81, + NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION = 82 } } @@ -10311,6 +10958,260 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } + /** Properties of a RedisInstanceInfo. */ + interface IRedisInstanceInfo { + + /** RedisInstanceInfo displayName */ + displayName?: (string|null); + + /** RedisInstanceInfo uri */ + uri?: (string|null); + + /** RedisInstanceInfo networkUri */ + networkUri?: (string|null); + + /** RedisInstanceInfo primaryEndpointIp */ + primaryEndpointIp?: (string|null); + + /** RedisInstanceInfo readEndpointIp */ + readEndpointIp?: (string|null); + + /** RedisInstanceInfo region */ + region?: (string|null); + } + + /** Represents a RedisInstanceInfo. */ + class RedisInstanceInfo implements IRedisInstanceInfo { + + /** + * Constructs a new RedisInstanceInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo); + + /** RedisInstanceInfo displayName. */ + public displayName: string; + + /** RedisInstanceInfo uri. */ + public uri: string; + + /** RedisInstanceInfo networkUri. */ + public networkUri: string; + + /** RedisInstanceInfo primaryEndpointIp. */ + public primaryEndpointIp: string; + + /** RedisInstanceInfo readEndpointIp. */ + public readEndpointIp: string; + + /** RedisInstanceInfo region. */ + public region: string; + + /** + * Creates a new RedisInstanceInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns RedisInstanceInfo instance + */ + public static create(properties?: google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo): google.cloud.networkmanagement.v1beta1.RedisInstanceInfo; + + /** + * Encodes the specified RedisInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.verify|verify} messages. + * @param message RedisInstanceInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified RedisInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.verify|verify} messages. + * @param message RedisInstanceInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a RedisInstanceInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns RedisInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1beta1.RedisInstanceInfo; + + /** + * Decodes a RedisInstanceInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns RedisInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1beta1.RedisInstanceInfo; + + /** + * Verifies a RedisInstanceInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a RedisInstanceInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns RedisInstanceInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1beta1.RedisInstanceInfo; + + /** + * Creates a plain object from a RedisInstanceInfo message. Also converts values to other types if specified. + * @param message RedisInstanceInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1beta1.RedisInstanceInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this RedisInstanceInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for RedisInstanceInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a RedisClusterInfo. */ + interface IRedisClusterInfo { + + /** RedisClusterInfo displayName */ + displayName?: (string|null); + + /** RedisClusterInfo uri */ + uri?: (string|null); + + /** RedisClusterInfo networkUri */ + networkUri?: (string|null); + + /** RedisClusterInfo discoveryEndpointIpAddress */ + discoveryEndpointIpAddress?: (string|null); + + /** RedisClusterInfo secondaryEndpointIpAddress */ + secondaryEndpointIpAddress?: (string|null); + + /** RedisClusterInfo location */ + location?: (string|null); + } + + /** Represents a RedisClusterInfo. */ + class RedisClusterInfo implements IRedisClusterInfo { + + /** + * Constructs a new RedisClusterInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.networkmanagement.v1beta1.IRedisClusterInfo); + + /** RedisClusterInfo displayName. */ + public displayName: string; + + /** RedisClusterInfo uri. */ + public uri: string; + + /** RedisClusterInfo networkUri. */ + public networkUri: string; + + /** RedisClusterInfo discoveryEndpointIpAddress. */ + public discoveryEndpointIpAddress: string; + + /** RedisClusterInfo secondaryEndpointIpAddress. */ + public secondaryEndpointIpAddress: string; + + /** RedisClusterInfo location. */ + public location: string; + + /** + * Creates a new RedisClusterInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns RedisClusterInfo instance + */ + public static create(properties?: google.cloud.networkmanagement.v1beta1.IRedisClusterInfo): google.cloud.networkmanagement.v1beta1.RedisClusterInfo; + + /** + * Encodes the specified RedisClusterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisClusterInfo.verify|verify} messages. + * @param message RedisClusterInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.networkmanagement.v1beta1.IRedisClusterInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified RedisClusterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisClusterInfo.verify|verify} messages. + * @param message RedisClusterInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.networkmanagement.v1beta1.IRedisClusterInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a RedisClusterInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns RedisClusterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1beta1.RedisClusterInfo; + + /** + * Decodes a RedisClusterInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns RedisClusterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1beta1.RedisClusterInfo; + + /** + * Verifies a RedisClusterInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a RedisClusterInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns RedisClusterInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1beta1.RedisClusterInfo; + + /** + * Creates a plain object from a RedisClusterInfo message. Also converts values to other types if specified. + * @param message RedisClusterInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1beta1.RedisClusterInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this RedisClusterInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for RedisClusterInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + /** Properties of a CloudFunctionInfo. */ interface ICloudFunctionInfo { @@ -11378,6 +12279,103 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } + /** Properties of a ServerlessNegInfo. */ + interface IServerlessNegInfo { + + /** ServerlessNegInfo negUri */ + negUri?: (string|null); + } + + /** Represents a ServerlessNegInfo. */ + class ServerlessNegInfo implements IServerlessNegInfo { + + /** + * Constructs a new ServerlessNegInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.networkmanagement.v1beta1.IServerlessNegInfo); + + /** ServerlessNegInfo negUri. */ + public negUri: string; + + /** + * Creates a new ServerlessNegInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns ServerlessNegInfo instance + */ + public static create(properties?: google.cloud.networkmanagement.v1beta1.IServerlessNegInfo): google.cloud.networkmanagement.v1beta1.ServerlessNegInfo; + + /** + * Encodes the specified ServerlessNegInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.verify|verify} messages. + * @param message ServerlessNegInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.networkmanagement.v1beta1.IServerlessNegInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ServerlessNegInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.verify|verify} messages. + * @param message ServerlessNegInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.networkmanagement.v1beta1.IServerlessNegInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ServerlessNegInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.networkmanagement.v1beta1.ServerlessNegInfo; + + /** + * Decodes a ServerlessNegInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.networkmanagement.v1beta1.ServerlessNegInfo; + + /** + * Verifies a ServerlessNegInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ServerlessNegInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ServerlessNegInfo + */ + public static fromObject(object: { [k: string]: any }): google.cloud.networkmanagement.v1beta1.ServerlessNegInfo; + + /** + * Creates a plain object from a ServerlessNegInfo message. Also converts values to other types if specified. + * @param message ServerlessNegInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.networkmanagement.v1beta1.ServerlessNegInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ServerlessNegInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ServerlessNegInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + /** Represents a ReachabilityService */ class ReachabilityService extends $protobuf.rpc.Service { diff --git a/packages/google-cloud-networkmanagement/protos/protos.js b/packages/google-cloud-networkmanagement/protos/protos.js index 3a1347f8e1a..00db996335c 100644 --- a/packages/google-cloud-networkmanagement/protos/protos.js +++ b/packages/google-cloud-networkmanagement/protos/protos.js @@ -644,6 +644,8 @@ * @property {google.cloud.networkmanagement.v1.LoadBalancerType|null} [loadBalancerType] Endpoint loadBalancerType * @property {string|null} [gkeMasterCluster] Endpoint gkeMasterCluster * @property {string|null} [cloudSqlInstance] Endpoint cloudSqlInstance + * @property {string|null} [redisInstance] Endpoint redisInstance + * @property {string|null} [redisCluster] Endpoint redisCluster * @property {google.cloud.networkmanagement.v1.Endpoint.ICloudFunctionEndpoint|null} [cloudFunction] Endpoint cloudFunction * @property {google.cloud.networkmanagement.v1.Endpoint.IAppEngineVersionEndpoint|null} [appEngineVersion] Endpoint appEngineVersion * @property {google.cloud.networkmanagement.v1.Endpoint.ICloudRunRevisionEndpoint|null} [cloudRunRevision] Endpoint cloudRunRevision @@ -739,6 +741,22 @@ */ Endpoint.prototype.cloudSqlInstance = ""; + /** + * Endpoint redisInstance. + * @member {string} redisInstance + * @memberof google.cloud.networkmanagement.v1.Endpoint + * @instance + */ + Endpoint.prototype.redisInstance = ""; + + /** + * Endpoint redisCluster. + * @member {string} redisCluster + * @memberof google.cloud.networkmanagement.v1.Endpoint + * @instance + */ + Endpoint.prototype.redisCluster = ""; + /** * Endpoint cloudFunction. * @member {google.cloud.networkmanagement.v1.Endpoint.ICloudFunctionEndpoint|null|undefined} cloudFunction @@ -877,6 +895,10 @@ writer.uint32(/* id 15, wireType 2 =*/122).string(message.loadBalancerId); if (message.loadBalancerType != null && Object.hasOwnProperty.call(message, "loadBalancerType")) writer.uint32(/* id 16, wireType 0 =*/128).int32(message.loadBalancerType); + if (message.redisInstance != null && Object.hasOwnProperty.call(message, "redisInstance")) + writer.uint32(/* id 17, wireType 2 =*/138).string(message.redisInstance); + if (message.redisCluster != null && Object.hasOwnProperty.call(message, "redisCluster")) + writer.uint32(/* id 18, wireType 2 =*/146).string(message.redisCluster); return writer; }; @@ -947,6 +969,14 @@ message.cloudSqlInstance = reader.string(); break; } + case 17: { + message.redisInstance = reader.string(); + break; + } + case 18: { + message.redisCluster = reader.string(); + break; + } case 10: { message.cloudFunction = $root.google.cloud.networkmanagement.v1.Endpoint.CloudFunctionEndpoint.decode(reader, reader.uint32()); break; @@ -1062,6 +1092,12 @@ if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) if (!$util.isString(message.cloudSqlInstance)) return "cloudSqlInstance: string expected"; + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) + if (!$util.isString(message.redisInstance)) + return "redisInstance: string expected"; + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) + if (!$util.isString(message.redisCluster)) + return "redisCluster: string expected"; if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { var error = $root.google.cloud.networkmanagement.v1.Endpoint.CloudFunctionEndpoint.verify(message.cloudFunction); if (error) @@ -1201,6 +1237,10 @@ message.gkeMasterCluster = String(object.gkeMasterCluster); if (object.cloudSqlInstance != null) message.cloudSqlInstance = String(object.cloudSqlInstance); + if (object.redisInstance != null) + message.redisInstance = String(object.redisInstance); + if (object.redisCluster != null) + message.redisCluster = String(object.redisCluster); if (object.cloudFunction != null) { if (typeof object.cloudFunction !== "object") throw TypeError(".google.cloud.networkmanagement.v1.Endpoint.cloudFunction: object expected"); @@ -1269,6 +1309,8 @@ object.appEngineVersion = null; object.cloudRunRevision = null; object.forwardingRule = ""; + object.redisInstance = ""; + object.redisCluster = ""; } if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) object.ipAddress = message.ipAddress; @@ -1309,6 +1351,10 @@ if (options.oneofs) object._loadBalancerType = "loadBalancerType"; } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) + object.redisInstance = message.redisInstance; + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) + object.redisCluster = message.redisCluster; return object; }; @@ -3824,6 +3870,8 @@ * @property {google.cloud.networkmanagement.v1.INetworkInfo|null} [network] Step network * @property {google.cloud.networkmanagement.v1.IGKEMasterInfo|null} [gkeMaster] Step gkeMaster * @property {google.cloud.networkmanagement.v1.ICloudSQLInstanceInfo|null} [cloudSqlInstance] Step cloudSqlInstance + * @property {google.cloud.networkmanagement.v1.IRedisInstanceInfo|null} [redisInstance] Step redisInstance + * @property {google.cloud.networkmanagement.v1.IRedisClusterInfo|null} [redisCluster] Step redisCluster * @property {google.cloud.networkmanagement.v1.ICloudFunctionInfo|null} [cloudFunction] Step cloudFunction * @property {google.cloud.networkmanagement.v1.IAppEngineVersionInfo|null} [appEngineVersion] Step appEngineVersion * @property {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo|null} [cloudRunRevision] Step cloudRunRevision @@ -3831,6 +3879,7 @@ * @property {google.cloud.networkmanagement.v1.IProxyConnectionInfo|null} [proxyConnection] Step proxyConnection * @property {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo|null} [loadBalancerBackendInfo] Step loadBalancerBackendInfo * @property {google.cloud.networkmanagement.v1.IStorageBucketInfo|null} [storageBucket] Step storageBucket + * @property {google.cloud.networkmanagement.v1.IServerlessNegInfo|null} [serverlessNeg] Step serverlessNeg */ /** @@ -4016,6 +4065,22 @@ */ Step.prototype.cloudSqlInstance = null; + /** + * Step redisInstance. + * @member {google.cloud.networkmanagement.v1.IRedisInstanceInfo|null|undefined} redisInstance + * @memberof google.cloud.networkmanagement.v1.Step + * @instance + */ + Step.prototype.redisInstance = null; + + /** + * Step redisCluster. + * @member {google.cloud.networkmanagement.v1.IRedisClusterInfo|null|undefined} redisCluster + * @memberof google.cloud.networkmanagement.v1.Step + * @instance + */ + Step.prototype.redisCluster = null; + /** * Step cloudFunction. * @member {google.cloud.networkmanagement.v1.ICloudFunctionInfo|null|undefined} cloudFunction @@ -4072,17 +4137,25 @@ */ Step.prototype.storageBucket = null; + /** + * Step serverlessNeg. + * @member {google.cloud.networkmanagement.v1.IServerlessNegInfo|null|undefined} serverlessNeg + * @memberof google.cloud.networkmanagement.v1.Step + * @instance + */ + Step.prototype.serverlessNeg = null; + // OneOf field names bound to virtual getters and setters var $oneOfFields; /** * Step stepInfo. - * @member {"instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|undefined} stepInfo + * @member {"instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"redisInstance"|"redisCluster"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|"serverlessNeg"|undefined} stepInfo * @memberof google.cloud.networkmanagement.v1.Step * @instance */ Object.defineProperty(Step.prototype, "stepInfo", { - get: $util.oneOfGetter($oneOfFields = ["instance", "firewall", "route", "endpoint", "googleService", "forwardingRule", "vpnGateway", "vpnTunnel", "vpcConnector", "deliver", "forward", "abort", "drop", "loadBalancer", "network", "gkeMaster", "cloudSqlInstance", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", "storageBucket"]), + get: $util.oneOfGetter($oneOfFields = ["instance", "firewall", "route", "endpoint", "googleService", "forwardingRule", "vpnGateway", "vpnTunnel", "vpcConnector", "deliver", "forward", "abort", "drop", "loadBalancer", "network", "gkeMaster", "cloudSqlInstance", "redisInstance", "redisCluster", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", "storageBucket", "serverlessNeg"]), set: $util.oneOfSetter($oneOfFields) }); @@ -4166,6 +4239,12 @@ $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.encode(message.loadBalancerBackendInfo, writer.uint32(/* id 27, wireType 2 =*/218).fork()).ldelim(); if (message.storageBucket != null && Object.hasOwnProperty.call(message, "storageBucket")) $root.google.cloud.networkmanagement.v1.StorageBucketInfo.encode(message.storageBucket, writer.uint32(/* id 28, wireType 2 =*/226).fork()).ldelim(); + if (message.serverlessNeg != null && Object.hasOwnProperty.call(message, "serverlessNeg")) + $root.google.cloud.networkmanagement.v1.ServerlessNegInfo.encode(message.serverlessNeg, writer.uint32(/* id 29, wireType 2 =*/234).fork()).ldelim(); + if (message.redisInstance != null && Object.hasOwnProperty.call(message, "redisInstance")) + $root.google.cloud.networkmanagement.v1.RedisInstanceInfo.encode(message.redisInstance, writer.uint32(/* id 30, wireType 2 =*/242).fork()).ldelim(); + if (message.redisCluster != null && Object.hasOwnProperty.call(message, "redisCluster")) + $root.google.cloud.networkmanagement.v1.RedisClusterInfo.encode(message.redisCluster, writer.uint32(/* id 31, wireType 2 =*/250).fork()).ldelim(); return writer; }; @@ -4284,6 +4363,14 @@ message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1.CloudSQLInstanceInfo.decode(reader, reader.uint32()); break; } + case 30: { + message.redisInstance = $root.google.cloud.networkmanagement.v1.RedisInstanceInfo.decode(reader, reader.uint32()); + break; + } + case 31: { + message.redisCluster = $root.google.cloud.networkmanagement.v1.RedisClusterInfo.decode(reader, reader.uint32()); + break; + } case 20: { message.cloudFunction = $root.google.cloud.networkmanagement.v1.CloudFunctionInfo.decode(reader, reader.uint32()); break; @@ -4312,6 +4399,10 @@ message.storageBucket = $root.google.cloud.networkmanagement.v1.StorageBucketInfo.decode(reader, reader.uint32()); break; } + case 29: { + message.serverlessNeg = $root.google.cloud.networkmanagement.v1.ServerlessNegInfo.decode(reader, reader.uint32()); + break; + } default: reader.skipType(tag & 7); break; @@ -4362,11 +4453,14 @@ case 3: case 21: case 22: + case 32: + case 33: case 23: case 25: case 26: case 29: case 30: + case 31: case 4: case 5: case 6: @@ -4562,6 +4656,26 @@ return "cloudSqlInstance." + error; } } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1.RedisInstanceInfo.verify(message.redisInstance); + if (error) + return "redisInstance." + error; + } + } + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1.RedisClusterInfo.verify(message.redisCluster); + if (error) + return "redisCluster." + error; + } + } if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { if (properties.stepInfo === 1) return "stepInfo: multiple values"; @@ -4632,6 +4746,16 @@ return "storageBucket." + error; } } + if (message.serverlessNeg != null && message.hasOwnProperty("serverlessNeg")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1.ServerlessNegInfo.verify(message.serverlessNeg); + if (error) + return "serverlessNeg." + error; + } + } return null; }; @@ -4684,6 +4808,14 @@ case 22: message.state = 22; break; + case "START_FROM_REDIS_INSTANCE": + case 32: + message.state = 32; + break; + case "START_FROM_REDIS_CLUSTER": + case 33: + message.state = 33; + break; case "START_FROM_CLOUD_FUNCTION": case 23: message.state = 23; @@ -4704,6 +4836,10 @@ case 30: message.state = 30; break; + case "START_FROM_SERVERLESS_NEG": + case 31: + message.state = 31; + break; case "APPLY_INGRESS_FIREWALL_RULE": case 4: message.state = 4; @@ -4870,6 +5006,16 @@ throw TypeError(".google.cloud.networkmanagement.v1.Step.cloudSqlInstance: object expected"); message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1.CloudSQLInstanceInfo.fromObject(object.cloudSqlInstance); } + if (object.redisInstance != null) { + if (typeof object.redisInstance !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.Step.redisInstance: object expected"); + message.redisInstance = $root.google.cloud.networkmanagement.v1.RedisInstanceInfo.fromObject(object.redisInstance); + } + if (object.redisCluster != null) { + if (typeof object.redisCluster !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.Step.redisCluster: object expected"); + message.redisCluster = $root.google.cloud.networkmanagement.v1.RedisClusterInfo.fromObject(object.redisCluster); + } if (object.cloudFunction != null) { if (typeof object.cloudFunction !== "object") throw TypeError(".google.cloud.networkmanagement.v1.Step.cloudFunction: object expected"); @@ -4905,6 +5051,11 @@ throw TypeError(".google.cloud.networkmanagement.v1.Step.storageBucket: object expected"); message.storageBucket = $root.google.cloud.networkmanagement.v1.StorageBucketInfo.fromObject(object.storageBucket); } + if (object.serverlessNeg != null) { + if (typeof object.serverlessNeg !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.Step.serverlessNeg: object expected"); + message.serverlessNeg = $root.google.cloud.networkmanagement.v1.ServerlessNegInfo.fromObject(object.serverlessNeg); + } return message; }; @@ -5055,6 +5206,21 @@ if (options.oneofs) object.stepInfo = "storageBucket"; } + if (message.serverlessNeg != null && message.hasOwnProperty("serverlessNeg")) { + object.serverlessNeg = $root.google.cloud.networkmanagement.v1.ServerlessNegInfo.toObject(message.serverlessNeg, options); + if (options.oneofs) + object.stepInfo = "serverlessNeg"; + } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) { + object.redisInstance = $root.google.cloud.networkmanagement.v1.RedisInstanceInfo.toObject(message.redisInstance, options); + if (options.oneofs) + object.stepInfo = "redisInstance"; + } + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) { + object.redisCluster = $root.google.cloud.networkmanagement.v1.RedisClusterInfo.toObject(message.redisCluster, options); + if (options.oneofs) + object.stepInfo = "redisCluster"; + } return object; }; @@ -5095,11 +5261,14 @@ * @property {number} START_FROM_PRIVATE_NETWORK=3 START_FROM_PRIVATE_NETWORK value * @property {number} START_FROM_GKE_MASTER=21 START_FROM_GKE_MASTER value * @property {number} START_FROM_CLOUD_SQL_INSTANCE=22 START_FROM_CLOUD_SQL_INSTANCE value + * @property {number} START_FROM_REDIS_INSTANCE=32 START_FROM_REDIS_INSTANCE value + * @property {number} START_FROM_REDIS_CLUSTER=33 START_FROM_REDIS_CLUSTER value * @property {number} START_FROM_CLOUD_FUNCTION=23 START_FROM_CLOUD_FUNCTION value * @property {number} START_FROM_APP_ENGINE_VERSION=25 START_FROM_APP_ENGINE_VERSION value * @property {number} START_FROM_CLOUD_RUN_REVISION=26 START_FROM_CLOUD_RUN_REVISION value * @property {number} START_FROM_STORAGE_BUCKET=29 START_FROM_STORAGE_BUCKET value * @property {number} START_FROM_PSC_PUBLISHED_SERVICE=30 START_FROM_PSC_PUBLISHED_SERVICE value + * @property {number} START_FROM_SERVERLESS_NEG=31 START_FROM_SERVERLESS_NEG value * @property {number} APPLY_INGRESS_FIREWALL_RULE=4 APPLY_INGRESS_FIREWALL_RULE value * @property {number} APPLY_EGRESS_FIREWALL_RULE=5 APPLY_EGRESS_FIREWALL_RULE value * @property {number} APPLY_ROUTE=6 APPLY_ROUTE value @@ -5129,11 +5298,14 @@ values[valuesById[3] = "START_FROM_PRIVATE_NETWORK"] = 3; values[valuesById[21] = "START_FROM_GKE_MASTER"] = 21; values[valuesById[22] = "START_FROM_CLOUD_SQL_INSTANCE"] = 22; + values[valuesById[32] = "START_FROM_REDIS_INSTANCE"] = 32; + values[valuesById[33] = "START_FROM_REDIS_CLUSTER"] = 33; values[valuesById[23] = "START_FROM_CLOUD_FUNCTION"] = 23; values[valuesById[25] = "START_FROM_APP_ENGINE_VERSION"] = 25; values[valuesById[26] = "START_FROM_CLOUD_RUN_REVISION"] = 26; values[valuesById[29] = "START_FROM_STORAGE_BUCKET"] = 29; values[valuesById[30] = "START_FROM_PSC_PUBLISHED_SERVICE"] = 30; + values[valuesById[31] = "START_FROM_SERVERLESS_NEG"] = 31; values[valuesById[4] = "APPLY_INGRESS_FIREWALL_RULE"] = 4; values[valuesById[5] = "APPLY_EGRESS_FIREWALL_RULE"] = 5; values[valuesById[6] = "APPLY_ROUTE"] = 6; @@ -5173,6 +5345,7 @@ * @property {string|null} [externalIp] InstanceInfo externalIp * @property {Array.|null} [networkTags] InstanceInfo networkTags * @property {string|null} [serviceAccount] InstanceInfo serviceAccount + * @property {string|null} [pscNetworkAttachmentUri] InstanceInfo pscNetworkAttachmentUri */ /** @@ -5255,6 +5428,14 @@ */ InstanceInfo.prototype.serviceAccount = ""; + /** + * InstanceInfo pscNetworkAttachmentUri. + * @member {string} pscNetworkAttachmentUri + * @memberof google.cloud.networkmanagement.v1.InstanceInfo + * @instance + */ + InstanceInfo.prototype.pscNetworkAttachmentUri = ""; + /** * Creates a new InstanceInfo instance using the specified properties. * @function create @@ -5296,6 +5477,8 @@ writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkTags[i]); if (message.serviceAccount != null && Object.hasOwnProperty.call(message, "serviceAccount")) writer.uint32(/* id 8, wireType 2 =*/66).string(message.serviceAccount); + if (message.pscNetworkAttachmentUri != null && Object.hasOwnProperty.call(message, "pscNetworkAttachmentUri")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.pscNetworkAttachmentUri); return writer; }; @@ -5364,6 +5547,10 @@ message.serviceAccount = reader.string(); break; } + case 9: { + message.pscNetworkAttachmentUri = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -5427,6 +5614,9 @@ if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) if (!$util.isString(message.serviceAccount)) return "serviceAccount: string expected"; + if (message.pscNetworkAttachmentUri != null && message.hasOwnProperty("pscNetworkAttachmentUri")) + if (!$util.isString(message.pscNetworkAttachmentUri)) + return "pscNetworkAttachmentUri: string expected"; return null; }; @@ -5463,6 +5653,8 @@ } if (object.serviceAccount != null) message.serviceAccount = String(object.serviceAccount); + if (object.pscNetworkAttachmentUri != null) + message.pscNetworkAttachmentUri = String(object.pscNetworkAttachmentUri); return message; }; @@ -5489,6 +5681,7 @@ object.internalIp = ""; object.externalIp = ""; object.serviceAccount = ""; + object.pscNetworkAttachmentUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -5509,6 +5702,8 @@ } if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) object.serviceAccount = message.serviceAccount; + if (message.pscNetworkAttachmentUri != null && message.hasOwnProperty("pscNetworkAttachmentUri")) + object.pscNetworkAttachmentUri = message.pscNetworkAttachmentUri; return object; }; @@ -5549,7 +5744,9 @@ * @interface INetworkInfo * @property {string|null} [displayName] NetworkInfo displayName * @property {string|null} [uri] NetworkInfo uri + * @property {string|null} [matchedSubnetUri] NetworkInfo matchedSubnetUri * @property {string|null} [matchedIpRange] NetworkInfo matchedIpRange + * @property {string|null} [region] NetworkInfo region */ /** @@ -5583,6 +5780,14 @@ */ NetworkInfo.prototype.uri = ""; + /** + * NetworkInfo matchedSubnetUri. + * @member {string} matchedSubnetUri + * @memberof google.cloud.networkmanagement.v1.NetworkInfo + * @instance + */ + NetworkInfo.prototype.matchedSubnetUri = ""; + /** * NetworkInfo matchedIpRange. * @member {string} matchedIpRange @@ -5591,6 +5796,14 @@ */ NetworkInfo.prototype.matchedIpRange = ""; + /** + * NetworkInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1.NetworkInfo + * @instance + */ + NetworkInfo.prototype.region = ""; + /** * Creates a new NetworkInfo instance using the specified properties. * @function create @@ -5621,6 +5834,10 @@ writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); if (message.matchedIpRange != null && Object.hasOwnProperty.call(message, "matchedIpRange")) writer.uint32(/* id 4, wireType 2 =*/34).string(message.matchedIpRange); + if (message.matchedSubnetUri != null && Object.hasOwnProperty.call(message, "matchedSubnetUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.matchedSubnetUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); return writer; }; @@ -5663,10 +5880,18 @@ message.uri = reader.string(); break; } + case 5: { + message.matchedSubnetUri = reader.string(); + break; + } case 4: { message.matchedIpRange = reader.string(); break; } + case 6: { + message.region = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -5708,9 +5933,15 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; + if (message.matchedSubnetUri != null && message.hasOwnProperty("matchedSubnetUri")) + if (!$util.isString(message.matchedSubnetUri)) + return "matchedSubnetUri: string expected"; if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) if (!$util.isString(message.matchedIpRange)) return "matchedIpRange: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; return null; }; @@ -5730,8 +5961,12 @@ message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); + if (object.matchedSubnetUri != null) + message.matchedSubnetUri = String(object.matchedSubnetUri); if (object.matchedIpRange != null) message.matchedIpRange = String(object.matchedIpRange); + if (object.region != null) + message.region = String(object.region); return message; }; @@ -5752,6 +5987,8 @@ object.displayName = ""; object.uri = ""; object.matchedIpRange = ""; + object.matchedSubnetUri = ""; + object.region = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -5759,6 +5996,10 @@ object.uri = message.uri; if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) object.matchedIpRange = message.matchedIpRange; + if (message.matchedSubnetUri != null && message.hasOwnProperty("matchedSubnetUri")) + object.matchedSubnetUri = message.matchedSubnetUri; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; @@ -5806,6 +6047,7 @@ * @property {Array.|null} [targetTags] FirewallInfo targetTags * @property {Array.|null} [targetServiceAccounts] FirewallInfo targetServiceAccounts * @property {string|null} [policy] FirewallInfo policy + * @property {string|null} [policyUri] FirewallInfo policyUri * @property {google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType|null} [firewallRuleType] FirewallInfo firewallRuleType */ @@ -5898,6 +6140,14 @@ */ FirewallInfo.prototype.policy = ""; + /** + * FirewallInfo policyUri. + * @member {string} policyUri + * @memberof google.cloud.networkmanagement.v1.FirewallInfo + * @instance + */ + FirewallInfo.prototype.policyUri = ""; + /** * FirewallInfo firewallRuleType. * @member {google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType} firewallRuleType @@ -5952,6 +6202,8 @@ writer.uint32(/* id 9, wireType 2 =*/74).string(message.policy); if (message.firewallRuleType != null && Object.hasOwnProperty.call(message, "firewallRuleType")) writer.uint32(/* id 10, wireType 0 =*/80).int32(message.firewallRuleType); + if (message.policyUri != null && Object.hasOwnProperty.call(message, "policyUri")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.policyUri); return writer; }; @@ -6026,6 +6278,10 @@ message.policy = reader.string(); break; } + case 11: { + message.policyUri = reader.string(); + break; + } case 10: { message.firewallRuleType = reader.int32(); break; @@ -6100,6 +6356,9 @@ if (message.policy != null && message.hasOwnProperty("policy")) if (!$util.isString(message.policy)) return "policy: string expected"; + if (message.policyUri != null && message.hasOwnProperty("policyUri")) + if (!$util.isString(message.policyUri)) + return "policyUri: string expected"; if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) switch (message.firewallRuleType) { default: @@ -6158,6 +6417,8 @@ } if (object.policy != null) message.policy = String(object.policy); + if (object.policyUri != null) + message.policyUri = String(object.policyUri); switch (object.firewallRuleType) { default: if (typeof object.firewallRuleType === "number") { @@ -6231,6 +6492,7 @@ object.networkUri = ""; object.policy = ""; object.firewallRuleType = options.enums === String ? "FIREWALL_RULE_TYPE_UNSPECIFIED" : 0; + object.policyUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -6258,6 +6520,8 @@ object.policy = message.policy; if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) object.firewallRuleType = options.enums === String ? $root.google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType[message.firewallRuleType] === undefined ? message.firewallRuleType : $root.google.cloud.networkmanagement.v1.FirewallInfo.FirewallRuleType[message.firewallRuleType] : message.firewallRuleType; + if (message.policyUri != null && message.hasOwnProperty("policyUri")) + object.policyUri = message.policyUri; return object; }; @@ -6329,6 +6593,7 @@ * @property {google.cloud.networkmanagement.v1.RouteInfo.RouteScope|null} [routeScope] RouteInfo routeScope * @property {string|null} [displayName] RouteInfo displayName * @property {string|null} [uri] RouteInfo uri + * @property {string|null} [region] RouteInfo region * @property {string|null} [destIpRange] RouteInfo destIpRange * @property {string|null} [nextHop] RouteInfo nextHop * @property {string|null} [networkUri] RouteInfo networkUri @@ -6340,6 +6605,8 @@ * @property {Array.|null} [protocols] RouteInfo protocols * @property {string|null} [nccHubUri] RouteInfo nccHubUri * @property {string|null} [nccSpokeUri] RouteInfo nccSpokeUri + * @property {string|null} [advertisedRouteSourceRouterUri] RouteInfo advertisedRouteSourceRouterUri + * @property {string|null} [advertisedRouteNextHopUri] RouteInfo advertisedRouteNextHopUri */ /** @@ -6401,6 +6668,14 @@ */ RouteInfo.prototype.uri = ""; + /** + * RouteInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1.RouteInfo + * @instance + */ + RouteInfo.prototype.region = ""; + /** * RouteInfo destIpRange. * @member {string} destIpRange @@ -6489,6 +6764,22 @@ */ RouteInfo.prototype.nccSpokeUri = null; + /** + * RouteInfo advertisedRouteSourceRouterUri. + * @member {string|null|undefined} advertisedRouteSourceRouterUri + * @memberof google.cloud.networkmanagement.v1.RouteInfo + * @instance + */ + RouteInfo.prototype.advertisedRouteSourceRouterUri = null; + + /** + * RouteInfo advertisedRouteNextHopUri. + * @member {string|null|undefined} advertisedRouteNextHopUri + * @memberof google.cloud.networkmanagement.v1.RouteInfo + * @instance + */ + RouteInfo.prototype.advertisedRouteNextHopUri = null; + // OneOf field names bound to virtual getters and setters var $oneOfFields; @@ -6514,6 +6805,28 @@ set: $util.oneOfSetter($oneOfFields) }); + /** + * RouteInfo _advertisedRouteSourceRouterUri. + * @member {"advertisedRouteSourceRouterUri"|undefined} _advertisedRouteSourceRouterUri + * @memberof google.cloud.networkmanagement.v1.RouteInfo + * @instance + */ + Object.defineProperty(RouteInfo.prototype, "_advertisedRouteSourceRouterUri", { + get: $util.oneOfGetter($oneOfFields = ["advertisedRouteSourceRouterUri"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * RouteInfo _advertisedRouteNextHopUri. + * @member {"advertisedRouteNextHopUri"|undefined} _advertisedRouteNextHopUri + * @memberof google.cloud.networkmanagement.v1.RouteInfo + * @instance + */ + Object.defineProperty(RouteInfo.prototype, "_advertisedRouteNextHopUri", { + get: $util.oneOfGetter($oneOfFields = ["advertisedRouteNextHopUri"]), + set: $util.oneOfSetter($oneOfFields) + }); + /** * Creates a new RouteInfo instance using the specified properties. * @function create @@ -6574,6 +6887,12 @@ writer.uint32(/* id 15, wireType 2 =*/122).string(message.nccHubUri); if (message.nccSpokeUri != null && Object.hasOwnProperty.call(message, "nccSpokeUri")) writer.uint32(/* id 16, wireType 2 =*/130).string(message.nccSpokeUri); + if (message.advertisedRouteSourceRouterUri != null && Object.hasOwnProperty.call(message, "advertisedRouteSourceRouterUri")) + writer.uint32(/* id 17, wireType 2 =*/138).string(message.advertisedRouteSourceRouterUri); + if (message.advertisedRouteNextHopUri != null && Object.hasOwnProperty.call(message, "advertisedRouteNextHopUri")) + writer.uint32(/* id 18, wireType 2 =*/146).string(message.advertisedRouteNextHopUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 19, wireType 2 =*/154).string(message.region); return writer; }; @@ -6628,6 +6947,10 @@ message.uri = reader.string(); break; } + case 19: { + message.region = reader.string(); + break; + } case 3: { message.destIpRange = reader.string(); break; @@ -6680,6 +7003,14 @@ message.nccSpokeUri = reader.string(); break; } + case 17: { + message.advertisedRouteSourceRouterUri = reader.string(); + break; + } + case 18: { + message.advertisedRouteNextHopUri = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -6728,6 +7059,7 @@ case 5: case 6: case 7: + case 101: break; } if (message.nextHopType != null && message.hasOwnProperty("nextHopType")) @@ -6764,6 +7096,9 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; if (message.destIpRange != null && message.hasOwnProperty("destIpRange")) if (!$util.isString(message.destIpRange)) return "destIpRange: string expected"; @@ -6817,6 +7152,16 @@ if (!$util.isString(message.nccSpokeUri)) return "nccSpokeUri: string expected"; } + if (message.advertisedRouteSourceRouterUri != null && message.hasOwnProperty("advertisedRouteSourceRouterUri")) { + properties._advertisedRouteSourceRouterUri = 1; + if (!$util.isString(message.advertisedRouteSourceRouterUri)) + return "advertisedRouteSourceRouterUri: string expected"; + } + if (message.advertisedRouteNextHopUri != null && message.hasOwnProperty("advertisedRouteNextHopUri")) { + properties._advertisedRouteNextHopUri = 1; + if (!$util.isString(message.advertisedRouteNextHopUri)) + return "advertisedRouteNextHopUri: string expected"; + } return null; }; @@ -6871,6 +7216,10 @@ case 7: message.routeType = 7; break; + case "ADVERTISED": + case 101: + message.routeType = 101; + break; } switch (object.nextHopType) { default: @@ -6956,6 +7305,8 @@ message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); + if (object.region != null) + message.region = String(object.region); if (object.destIpRange != null) message.destIpRange = String(object.destIpRange); if (object.nextHop != null) @@ -6998,6 +7349,10 @@ message.nccHubUri = String(object.nccHubUri); if (object.nccSpokeUri != null) message.nccSpokeUri = String(object.nccSpokeUri); + if (object.advertisedRouteSourceRouterUri != null) + message.advertisedRouteSourceRouterUri = String(object.advertisedRouteSourceRouterUri); + if (object.advertisedRouteNextHopUri != null) + message.advertisedRouteNextHopUri = String(object.advertisedRouteNextHopUri); return message; }; @@ -7031,6 +7386,7 @@ object.nextHopType = options.enums === String ? "NEXT_HOP_TYPE_UNSPECIFIED" : 0; object.srcIpRange = ""; object.routeScope = options.enums === String ? "ROUTE_SCOPE_UNSPECIFIED" : 0; + object.region = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -7082,6 +7438,18 @@ if (options.oneofs) object._nccSpokeUri = "nccSpokeUri"; } + if (message.advertisedRouteSourceRouterUri != null && message.hasOwnProperty("advertisedRouteSourceRouterUri")) { + object.advertisedRouteSourceRouterUri = message.advertisedRouteSourceRouterUri; + if (options.oneofs) + object._advertisedRouteSourceRouterUri = "advertisedRouteSourceRouterUri"; + } + if (message.advertisedRouteNextHopUri != null && message.hasOwnProperty("advertisedRouteNextHopUri")) { + object.advertisedRouteNextHopUri = message.advertisedRouteNextHopUri; + if (options.oneofs) + object._advertisedRouteNextHopUri = "advertisedRouteNextHopUri"; + } + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; @@ -7123,6 +7491,7 @@ * @property {number} PEERING_STATIC=5 PEERING_STATIC value * @property {number} PEERING_DYNAMIC=6 PEERING_DYNAMIC value * @property {number} POLICY_BASED=7 POLICY_BASED value + * @property {number} ADVERTISED=101 ADVERTISED value */ RouteInfo.RouteType = (function() { var valuesById = {}, values = Object.create(valuesById); @@ -7134,6 +7503,7 @@ values[valuesById[5] = "PEERING_STATIC"] = 5; values[valuesById[6] = "PEERING_DYNAMIC"] = 6; values[valuesById[7] = "POLICY_BASED"] = 7; + values[valuesById[101] = "ADVERTISED"] = 101; return values; })(); @@ -7500,6 +7870,10 @@ * @property {string|null} [vip] ForwardingRuleInfo vip * @property {string|null} [target] ForwardingRuleInfo target * @property {string|null} [networkUri] ForwardingRuleInfo networkUri + * @property {string|null} [region] ForwardingRuleInfo region + * @property {string|null} [loadBalancerName] ForwardingRuleInfo loadBalancerName + * @property {string|null} [pscServiceAttachmentUri] ForwardingRuleInfo pscServiceAttachmentUri + * @property {string|null} [pscGoogleApiTarget] ForwardingRuleInfo pscGoogleApiTarget */ /** @@ -7573,6 +7947,38 @@ */ ForwardingRuleInfo.prototype.networkUri = ""; + /** + * ForwardingRuleInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.region = ""; + + /** + * ForwardingRuleInfo loadBalancerName. + * @member {string} loadBalancerName + * @memberof google.cloud.networkmanagement.v1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.loadBalancerName = ""; + + /** + * ForwardingRuleInfo pscServiceAttachmentUri. + * @member {string} pscServiceAttachmentUri + * @memberof google.cloud.networkmanagement.v1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.pscServiceAttachmentUri = ""; + + /** + * ForwardingRuleInfo pscGoogleApiTarget. + * @member {string} pscGoogleApiTarget + * @memberof google.cloud.networkmanagement.v1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.pscGoogleApiTarget = ""; + /** * Creates a new ForwardingRuleInfo instance using the specified properties. * @function create @@ -7611,6 +8017,14 @@ writer.uint32(/* id 6, wireType 2 =*/50).string(message.matchedPortRange); if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.region); + if (message.loadBalancerName != null && Object.hasOwnProperty.call(message, "loadBalancerName")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.loadBalancerName); + if (message.pscServiceAttachmentUri != null && Object.hasOwnProperty.call(message, "pscServiceAttachmentUri")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.pscServiceAttachmentUri); + if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.pscGoogleApiTarget); return writer; }; @@ -7673,6 +8087,22 @@ message.networkUri = reader.string(); break; } + case 8: { + message.region = reader.string(); + break; + } + case 9: { + message.loadBalancerName = reader.string(); + break; + } + case 10: { + message.pscServiceAttachmentUri = reader.string(); + break; + } + case 11: { + message.pscGoogleApiTarget = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -7729,6 +8159,18 @@ if (message.networkUri != null && message.hasOwnProperty("networkUri")) if (!$util.isString(message.networkUri)) return "networkUri: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; + if (message.loadBalancerName != null && message.hasOwnProperty("loadBalancerName")) + if (!$util.isString(message.loadBalancerName)) + return "loadBalancerName: string expected"; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + if (!$util.isString(message.pscServiceAttachmentUri)) + return "pscServiceAttachmentUri: string expected"; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + if (!$util.isString(message.pscGoogleApiTarget)) + return "pscGoogleApiTarget: string expected"; return null; }; @@ -7758,6 +8200,14 @@ message.target = String(object.target); if (object.networkUri != null) message.networkUri = String(object.networkUri); + if (object.region != null) + message.region = String(object.region); + if (object.loadBalancerName != null) + message.loadBalancerName = String(object.loadBalancerName); + if (object.pscServiceAttachmentUri != null) + message.pscServiceAttachmentUri = String(object.pscServiceAttachmentUri); + if (object.pscGoogleApiTarget != null) + message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); return message; }; @@ -7782,6 +8232,10 @@ object.target = ""; object.matchedPortRange = ""; object.networkUri = ""; + object.region = ""; + object.loadBalancerName = ""; + object.pscServiceAttachmentUri = ""; + object.pscGoogleApiTarget = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -7797,6 +8251,14 @@ object.matchedPortRange = message.matchedPortRange; if (message.networkUri != null && message.hasOwnProperty("networkUri")) object.networkUri = message.networkUri; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; + if (message.loadBalancerName != null && message.hasOwnProperty("loadBalancerName")) + object.loadBalancerName = message.loadBalancerName; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + object.pscServiceAttachmentUri = message.pscServiceAttachmentUri; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + object.pscGoogleApiTarget = message.pscGoogleApiTarget; return object; }; @@ -9753,6 +10215,8 @@ * @property {google.cloud.networkmanagement.v1.DeliverInfo.Target|null} [target] DeliverInfo target * @property {string|null} [resourceUri] DeliverInfo resourceUri * @property {string|null} [ipAddress] DeliverInfo ipAddress + * @property {string|null} [storageBucket] DeliverInfo storageBucket + * @property {string|null} [pscGoogleApiTarget] DeliverInfo pscGoogleApiTarget */ /** @@ -9794,6 +10258,22 @@ */ DeliverInfo.prototype.ipAddress = ""; + /** + * DeliverInfo storageBucket. + * @member {string} storageBucket + * @memberof google.cloud.networkmanagement.v1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.storageBucket = ""; + + /** + * DeliverInfo pscGoogleApiTarget. + * @member {string} pscGoogleApiTarget + * @memberof google.cloud.networkmanagement.v1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.pscGoogleApiTarget = ""; + /** * Creates a new DeliverInfo instance using the specified properties. * @function create @@ -9824,7 +10304,11 @@ writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) writer.uint32(/* id 3, wireType 2 =*/26).string(message.ipAddress); - return writer; + if (message.storageBucket != null && Object.hasOwnProperty.call(message, "storageBucket")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.storageBucket); + if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.pscGoogleApiTarget); + return writer; }; /** @@ -9870,6 +10354,14 @@ message.ipAddress = reader.string(); break; } + case 4: { + message.storageBucket = reader.string(); + break; + } + case 5: { + message.pscGoogleApiTarget = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -9924,6 +10416,9 @@ case 12: case 13: case 14: + case 15: + case 16: + case 17: break; } if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) @@ -9932,6 +10427,12 @@ if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) if (!$util.isString(message.ipAddress)) return "ipAddress: string expected"; + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) + if (!$util.isString(message.storageBucket)) + return "storageBucket: string expected"; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + if (!$util.isString(message.pscGoogleApiTarget)) + return "pscGoogleApiTarget: string expected"; return null; }; @@ -10014,11 +10515,27 @@ case 14: message.target = 14; break; + case "GOOGLE_MANAGED_SERVICE": + case 15: + message.target = 15; + break; + case "REDIS_INSTANCE": + case 16: + message.target = 16; + break; + case "REDIS_CLUSTER": + case 17: + message.target = 17; + break; } if (object.resourceUri != null) message.resourceUri = String(object.resourceUri); if (object.ipAddress != null) message.ipAddress = String(object.ipAddress); + if (object.storageBucket != null) + message.storageBucket = String(object.storageBucket); + if (object.pscGoogleApiTarget != null) + message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); return message; }; @@ -10039,6 +10556,8 @@ object.target = options.enums === String ? "TARGET_UNSPECIFIED" : 0; object.resourceUri = ""; object.ipAddress = ""; + object.storageBucket = ""; + object.pscGoogleApiTarget = ""; } if (message.target != null && message.hasOwnProperty("target")) object.target = options.enums === String ? $root.google.cloud.networkmanagement.v1.DeliverInfo.Target[message.target] === undefined ? message.target : $root.google.cloud.networkmanagement.v1.DeliverInfo.Target[message.target] : message.target; @@ -10046,6 +10565,10 @@ object.resourceUri = message.resourceUri; if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) object.ipAddress = message.ipAddress; + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) + object.storageBucket = message.storageBucket; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + object.pscGoogleApiTarget = message.pscGoogleApiTarget; return object; }; @@ -10094,6 +10617,9 @@ * @property {number} CLOUD_FUNCTION=12 CLOUD_FUNCTION value * @property {number} APP_ENGINE_VERSION=13 APP_ENGINE_VERSION value * @property {number} CLOUD_RUN_REVISION=14 CLOUD_RUN_REVISION value + * @property {number} GOOGLE_MANAGED_SERVICE=15 GOOGLE_MANAGED_SERVICE value + * @property {number} REDIS_INSTANCE=16 REDIS_INSTANCE value + * @property {number} REDIS_CLUSTER=17 REDIS_CLUSTER value */ DeliverInfo.Target = (function() { var valuesById = {}, values = Object.create(valuesById); @@ -10112,6 +10638,9 @@ values[valuesById[12] = "CLOUD_FUNCTION"] = 12; values[valuesById[13] = "APP_ENGINE_VERSION"] = 13; values[valuesById[14] = "CLOUD_RUN_REVISION"] = 14; + values[valuesById[15] = "GOOGLE_MANAGED_SERVICE"] = 15; + values[valuesById[16] = "REDIS_INSTANCE"] = 16; + values[valuesById[17] = "REDIS_CLUSTER"] = 17; return values; })(); @@ -10651,10 +11180,12 @@ case 13: case 14: case 2: + case 32: case 23: case 4: case 28: case 29: + case 36: case 5: case 6: case 9: @@ -10669,6 +11200,8 @@ case 27: case 19: case 20: + case 34: + case 35: case 21: case 22: case 30: @@ -10750,6 +11283,10 @@ case 2: message.cause = 2; break; + case "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP": + case 32: + message.cause = 32; + break; case "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK": case 23: message.cause = 23; @@ -10766,6 +11303,10 @@ case 29: message.cause = 29; break; + case "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS": + case 36: + message.cause = 36; + break; case "NO_SOURCE_LOCATION": case 5: message.cause = 5; @@ -10822,6 +11363,14 @@ case 20: message.cause = 20; break; + case "SOURCE_REDIS_CLUSTER_UNSUPPORTED": + case 34: + message.cause = 34; + break; + case "SOURCE_REDIS_INSTANCE_UNSUPPORTED": + case 35: + message.cause = 35; + break; case "SOURCE_FORWARDING_RULE_UNSUPPORTED": case 21: message.cause = 21; @@ -10927,10 +11476,12 @@ * @property {number} DESTINATION_ENDPOINT_NOT_FOUND=13 DESTINATION_ENDPOINT_NOT_FOUND value * @property {number} MISMATCHED_DESTINATION_NETWORK=14 MISMATCHED_DESTINATION_NETWORK value * @property {number} UNKNOWN_IP=2 UNKNOWN_IP value + * @property {number} GOOGLE_MANAGED_SERVICE_UNKNOWN_IP=32 GOOGLE_MANAGED_SERVICE_UNKNOWN_IP value * @property {number} SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK=23 SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK value * @property {number} PERMISSION_DENIED=4 PERMISSION_DENIED value * @property {number} PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS=28 PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS value * @property {number} PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS=29 PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS value + * @property {number} PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS=36 PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS value * @property {number} NO_SOURCE_LOCATION=5 NO_SOURCE_LOCATION value * @property {number} INVALID_ARGUMENT=6 INVALID_ARGUMENT value * @property {number} TRACE_TOO_LONG=9 TRACE_TOO_LONG value @@ -10945,6 +11496,8 @@ * @property {number} ROUTE_CONFIG_NOT_FOUND=27 ROUTE_CONFIG_NOT_FOUND value * @property {number} GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT=19 GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT value * @property {number} SOURCE_PSC_CLOUD_SQL_UNSUPPORTED=20 SOURCE_PSC_CLOUD_SQL_UNSUPPORTED value + * @property {number} SOURCE_REDIS_CLUSTER_UNSUPPORTED=34 SOURCE_REDIS_CLUSTER_UNSUPPORTED value + * @property {number} SOURCE_REDIS_INSTANCE_UNSUPPORTED=35 SOURCE_REDIS_INSTANCE_UNSUPPORTED value * @property {number} SOURCE_FORWARDING_RULE_UNSUPPORTED=21 SOURCE_FORWARDING_RULE_UNSUPPORTED value * @property {number} NON_ROUTABLE_IP_ADDRESS=22 NON_ROUTABLE_IP_ADDRESS value * @property {number} UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT=30 UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT value @@ -10962,10 +11515,12 @@ values[valuesById[13] = "DESTINATION_ENDPOINT_NOT_FOUND"] = 13; values[valuesById[14] = "MISMATCHED_DESTINATION_NETWORK"] = 14; values[valuesById[2] = "UNKNOWN_IP"] = 2; + values[valuesById[32] = "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP"] = 32; values[valuesById[23] = "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK"] = 23; values[valuesById[4] = "PERMISSION_DENIED"] = 4; values[valuesById[28] = "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS"] = 28; values[valuesById[29] = "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS"] = 29; + values[valuesById[36] = "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS"] = 36; values[valuesById[5] = "NO_SOURCE_LOCATION"] = 5; values[valuesById[6] = "INVALID_ARGUMENT"] = 6; values[valuesById[9] = "TRACE_TOO_LONG"] = 9; @@ -10980,6 +11535,8 @@ values[valuesById[27] = "ROUTE_CONFIG_NOT_FOUND"] = 27; values[valuesById[19] = "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT"] = 19; values[valuesById[20] = "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED"] = 20; + values[valuesById[34] = "SOURCE_REDIS_CLUSTER_UNSUPPORTED"] = 34; + values[valuesById[35] = "SOURCE_REDIS_INSTANCE_UNSUPPORTED"] = 35; values[valuesById[21] = "SOURCE_FORWARDING_RULE_UNSUPPORTED"] = 21; values[valuesById[22] = "NON_ROUTABLE_IP_ADDRESS"] = 22; values[valuesById[30] = "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT"] = 30; @@ -11213,6 +11770,8 @@ case 14: case 27: case 28: + case 68: + case 69: case 15: case 16: case 17: @@ -11228,9 +11787,12 @@ case 33: case 34: case 35: + case 63: case 22: case 23: case 24: + case 60: + case 61: case 25: case 26: case 41: @@ -11238,6 +11800,7 @@ case 54: case 58: case 57: + case 64: case 55: case 56: case 29: @@ -11245,6 +11808,23 @@ case 39: case 40: case 59: + case 62: + case 65: + case 66: + case 67: + case 70: + case 71: + case 72: + case 73: + case 74: + case 78: + case 75: + case 76: + case 77: + case 79: + case 80: + case 81: + case 82: break; } if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) @@ -11393,6 +11973,14 @@ case 28: message.cause = 28; break; + case "REDIS_INSTANCE_NOT_RUNNING": + case 68: + message.cause = 68; + break; + case "REDIS_CLUSTER_NOT_RUNNING": + case 69: + message.cause = 69; + break; case "TRAFFIC_TYPE_BLOCKED": case 15: message.cause = 15; @@ -11453,6 +12041,10 @@ case 35: message.cause = 35; break; + case "CLOUD_SQL_CONNECTOR_REQUIRED": + case 63: + message.cause = 63; + break; case "CLOUD_FUNCTION_NOT_ACTIVE": case 22: message.cause = 22; @@ -11465,6 +12057,14 @@ case 24: message.cause = 24; break; + case "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED": + case 60: + message.cause = 60; + break; + case "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED": + case 61: + message.cause = 61; + break; case "FORWARDING_RULE_REGION_MISMATCH": case 25: message.cause = 25; @@ -11493,6 +12093,10 @@ case 57: message.cause = 57; break; + case "PSC_TRANSITIVITY_NOT_PROPAGATED": + case 64: + message.cause = 64; + break; case "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED": case 55: message.cause = 55; @@ -11521,6 +12125,74 @@ case 59: message.cause = 59; break; + case "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE": + case 62: + message.cause = 62; + break; + case "LOAD_BALANCER_BACKEND_INVALID_NETWORK": + case 65: + message.cause = 65; + break; + case "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED": + case 66: + message.cause = 66; + break; + case "DESTINATION_IS_PRIVATE_NAT_IP_RANGE": + case 67: + message.cause = 67; + break; + case "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE": + case 70: + message.cause = 70; + break; + case "REDIS_INSTANCE_UNSUPPORTED_PORT": + case 71: + message.cause = 71; + break; + case "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS": + case 72: + message.cause = 72; + break; + case "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK": + case 73: + message.cause = 73; + break; + case "REDIS_INSTANCE_NO_EXTERNAL_IP": + case 74: + message.cause = 74; + break; + case "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL": + case 78: + message.cause = 78; + break; + case "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE": + case 75: + message.cause = 75; + break; + case "REDIS_CLUSTER_UNSUPPORTED_PORT": + case 76: + message.cause = 76; + break; + case "REDIS_CLUSTER_NO_EXTERNAL_IP": + case 77: + message.cause = 77; + break; + case "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL": + case 79: + message.cause = 79; + break; + case "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION": + case 80: + message.cause = 80; + break; + case "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION": + case 81: + message.cause = 81; + break; + case "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION": + case 82: + message.cause = 82; + break; } if (object.resourceUri != null) message.resourceUri = String(object.resourceUri); @@ -11624,6 +12296,8 @@ * @property {number} INSTANCE_NOT_RUNNING=14 INSTANCE_NOT_RUNNING value * @property {number} GKE_CLUSTER_NOT_RUNNING=27 GKE_CLUSTER_NOT_RUNNING value * @property {number} CLOUD_SQL_INSTANCE_NOT_RUNNING=28 CLOUD_SQL_INSTANCE_NOT_RUNNING value + * @property {number} REDIS_INSTANCE_NOT_RUNNING=68 REDIS_INSTANCE_NOT_RUNNING value + * @property {number} REDIS_CLUSTER_NOT_RUNNING=69 REDIS_CLUSTER_NOT_RUNNING value * @property {number} TRAFFIC_TYPE_BLOCKED=15 TRAFFIC_TYPE_BLOCKED value * @property {number} GKE_MASTER_UNAUTHORIZED_ACCESS=16 GKE_MASTER_UNAUTHORIZED_ACCESS value * @property {number} CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS=17 CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS value @@ -11639,9 +12313,12 @@ * @property {number} CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC=33 CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC value * @property {number} PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION=34 PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION value * @property {number} CLOUD_SQL_INSTANCE_NO_ROUTE=35 CLOUD_SQL_INSTANCE_NO_ROUTE value + * @property {number} CLOUD_SQL_CONNECTOR_REQUIRED=63 CLOUD_SQL_CONNECTOR_REQUIRED value * @property {number} CLOUD_FUNCTION_NOT_ACTIVE=22 CLOUD_FUNCTION_NOT_ACTIVE value * @property {number} VPC_CONNECTOR_NOT_SET=23 VPC_CONNECTOR_NOT_SET value * @property {number} VPC_CONNECTOR_NOT_RUNNING=24 VPC_CONNECTOR_NOT_RUNNING value + * @property {number} VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED=60 VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED value + * @property {number} VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED=61 VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED value * @property {number} FORWARDING_RULE_REGION_MISMATCH=25 FORWARDING_RULE_REGION_MISMATCH value * @property {number} PSC_CONNECTION_NOT_ACCEPTED=26 PSC_CONNECTION_NOT_ACCEPTED value * @property {number} PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK=41 PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK value @@ -11649,6 +12326,7 @@ * @property {number} PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS=54 PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS value * @property {number} CLOUD_SQL_PSC_NEG_UNSUPPORTED=58 CLOUD_SQL_PSC_NEG_UNSUPPORTED value * @property {number} NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT=57 NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT value + * @property {number} PSC_TRANSITIVITY_NOT_PROPAGATED=64 PSC_TRANSITIVITY_NOT_PROPAGATED value * @property {number} HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED=55 HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED value * @property {number} HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED=56 HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED value * @property {number} CLOUD_RUN_REVISION_NOT_READY=29 CLOUD_RUN_REVISION_NOT_READY value @@ -11656,6 +12334,23 @@ * @property {number} LOAD_BALANCER_HAS_NO_PROXY_SUBNET=39 LOAD_BALANCER_HAS_NO_PROXY_SUBNET value * @property {number} CLOUD_NAT_NO_ADDRESSES=40 CLOUD_NAT_NO_ADDRESSES value * @property {number} ROUTING_LOOP=59 ROUTING_LOOP value + * @property {number} DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE=62 DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE value + * @property {number} LOAD_BALANCER_BACKEND_INVALID_NETWORK=65 LOAD_BALANCER_BACKEND_INVALID_NETWORK value + * @property {number} BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED=66 BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED value + * @property {number} DESTINATION_IS_PRIVATE_NAT_IP_RANGE=67 DESTINATION_IS_PRIVATE_NAT_IP_RANGE value + * @property {number} DROPPED_INSIDE_REDIS_INSTANCE_SERVICE=70 DROPPED_INSIDE_REDIS_INSTANCE_SERVICE value + * @property {number} REDIS_INSTANCE_UNSUPPORTED_PORT=71 REDIS_INSTANCE_UNSUPPORTED_PORT value + * @property {number} REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS=72 REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS value + * @property {number} REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK=73 REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK value + * @property {number} REDIS_INSTANCE_NO_EXTERNAL_IP=74 REDIS_INSTANCE_NO_EXTERNAL_IP value + * @property {number} REDIS_INSTANCE_UNSUPPORTED_PROTOCOL=78 REDIS_INSTANCE_UNSUPPORTED_PROTOCOL value + * @property {number} DROPPED_INSIDE_REDIS_CLUSTER_SERVICE=75 DROPPED_INSIDE_REDIS_CLUSTER_SERVICE value + * @property {number} REDIS_CLUSTER_UNSUPPORTED_PORT=76 REDIS_CLUSTER_UNSUPPORTED_PORT value + * @property {number} REDIS_CLUSTER_NO_EXTERNAL_IP=77 REDIS_CLUSTER_NO_EXTERNAL_IP value + * @property {number} REDIS_CLUSTER_UNSUPPORTED_PROTOCOL=79 REDIS_CLUSTER_UNSUPPORTED_PROTOCOL value + * @property {number} NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION=80 NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION value + * @property {number} NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION=81 NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION value + * @property {number} NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION=82 NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION value */ DropInfo.Cause = (function() { var valuesById = {}, values = Object.create(valuesById); @@ -11687,6 +12382,8 @@ values[valuesById[14] = "INSTANCE_NOT_RUNNING"] = 14; values[valuesById[27] = "GKE_CLUSTER_NOT_RUNNING"] = 27; values[valuesById[28] = "CLOUD_SQL_INSTANCE_NOT_RUNNING"] = 28; + values[valuesById[68] = "REDIS_INSTANCE_NOT_RUNNING"] = 68; + values[valuesById[69] = "REDIS_CLUSTER_NOT_RUNNING"] = 69; values[valuesById[15] = "TRAFFIC_TYPE_BLOCKED"] = 15; values[valuesById[16] = "GKE_MASTER_UNAUTHORIZED_ACCESS"] = 16; values[valuesById[17] = "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS"] = 17; @@ -11702,9 +12399,12 @@ values[valuesById[33] = "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC"] = 33; values[valuesById[34] = "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION"] = 34; values[valuesById[35] = "CLOUD_SQL_INSTANCE_NO_ROUTE"] = 35; + values[valuesById[63] = "CLOUD_SQL_CONNECTOR_REQUIRED"] = 63; values[valuesById[22] = "CLOUD_FUNCTION_NOT_ACTIVE"] = 22; values[valuesById[23] = "VPC_CONNECTOR_NOT_SET"] = 23; values[valuesById[24] = "VPC_CONNECTOR_NOT_RUNNING"] = 24; + values[valuesById[60] = "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED"] = 60; + values[valuesById[61] = "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED"] = 61; values[valuesById[25] = "FORWARDING_RULE_REGION_MISMATCH"] = 25; values[valuesById[26] = "PSC_CONNECTION_NOT_ACCEPTED"] = 26; values[valuesById[41] = "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK"] = 41; @@ -11712,6 +12412,7 @@ values[valuesById[54] = "PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS"] = 54; values[valuesById[58] = "CLOUD_SQL_PSC_NEG_UNSUPPORTED"] = 58; values[valuesById[57] = "NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT"] = 57; + values[valuesById[64] = "PSC_TRANSITIVITY_NOT_PROPAGATED"] = 64; values[valuesById[55] = "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED"] = 55; values[valuesById[56] = "HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED"] = 56; values[valuesById[29] = "CLOUD_RUN_REVISION_NOT_READY"] = 29; @@ -11719,6 +12420,23 @@ values[valuesById[39] = "LOAD_BALANCER_HAS_NO_PROXY_SUBNET"] = 39; values[valuesById[40] = "CLOUD_NAT_NO_ADDRESSES"] = 40; values[valuesById[59] = "ROUTING_LOOP"] = 59; + values[valuesById[62] = "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE"] = 62; + values[valuesById[65] = "LOAD_BALANCER_BACKEND_INVALID_NETWORK"] = 65; + values[valuesById[66] = "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED"] = 66; + values[valuesById[67] = "DESTINATION_IS_PRIVATE_NAT_IP_RANGE"] = 67; + values[valuesById[70] = "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE"] = 70; + values[valuesById[71] = "REDIS_INSTANCE_UNSUPPORTED_PORT"] = 71; + values[valuesById[72] = "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS"] = 72; + values[valuesById[73] = "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK"] = 73; + values[valuesById[74] = "REDIS_INSTANCE_NO_EXTERNAL_IP"] = 74; + values[valuesById[78] = "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL"] = 78; + values[valuesById[75] = "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE"] = 75; + values[valuesById[76] = "REDIS_CLUSTER_UNSUPPORTED_PORT"] = 76; + values[valuesById[77] = "REDIS_CLUSTER_NO_EXTERNAL_IP"] = 77; + values[valuesById[79] = "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL"] = 79; + values[valuesById[80] = "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION"] = 80; + values[valuesById[81] = "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION"] = 81; + values[valuesById[82] = "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION"] = 82; return values; })(); @@ -12317,27 +13035,29 @@ return CloudSQLInstanceInfo; })(); - v1.CloudFunctionInfo = (function() { + v1.RedisInstanceInfo = (function() { /** - * Properties of a CloudFunctionInfo. + * Properties of a RedisInstanceInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface ICloudFunctionInfo - * @property {string|null} [displayName] CloudFunctionInfo displayName - * @property {string|null} [uri] CloudFunctionInfo uri - * @property {string|null} [location] CloudFunctionInfo location - * @property {number|Long|null} [versionId] CloudFunctionInfo versionId + * @interface IRedisInstanceInfo + * @property {string|null} [displayName] RedisInstanceInfo displayName + * @property {string|null} [uri] RedisInstanceInfo uri + * @property {string|null} [networkUri] RedisInstanceInfo networkUri + * @property {string|null} [primaryEndpointIp] RedisInstanceInfo primaryEndpointIp + * @property {string|null} [readEndpointIp] RedisInstanceInfo readEndpointIp + * @property {string|null} [region] RedisInstanceInfo region */ /** - * Constructs a new CloudFunctionInfo. + * Constructs a new RedisInstanceInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a CloudFunctionInfo. - * @implements ICloudFunctionInfo + * @classdesc Represents a RedisInstanceInfo. + * @implements IRedisInstanceInfo * @constructor - * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IRedisInstanceInfo=} [properties] Properties to set */ - function CloudFunctionInfo(properties) { + function RedisInstanceInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -12345,100 +13065,120 @@ } /** - * CloudFunctionInfo displayName. + * RedisInstanceInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @instance */ - CloudFunctionInfo.prototype.displayName = ""; + RedisInstanceInfo.prototype.displayName = ""; /** - * CloudFunctionInfo uri. + * RedisInstanceInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @instance */ - CloudFunctionInfo.prototype.uri = ""; + RedisInstanceInfo.prototype.uri = ""; /** - * CloudFunctionInfo location. - * @member {string} location - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * RedisInstanceInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @instance */ - CloudFunctionInfo.prototype.location = ""; + RedisInstanceInfo.prototype.networkUri = ""; /** - * CloudFunctionInfo versionId. - * @member {number|Long} versionId - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * RedisInstanceInfo primaryEndpointIp. + * @member {string} primaryEndpointIp + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @instance */ - CloudFunctionInfo.prototype.versionId = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + RedisInstanceInfo.prototype.primaryEndpointIp = ""; /** - * Creates a new CloudFunctionInfo instance using the specified properties. + * RedisInstanceInfo readEndpointIp. + * @member {string} readEndpointIp + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo + * @instance + */ + RedisInstanceInfo.prototype.readEndpointIp = ""; + + /** + * RedisInstanceInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo + * @instance + */ + RedisInstanceInfo.prototype.region = ""; + + /** + * Creates a new RedisInstanceInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo instance + * @param {google.cloud.networkmanagement.v1.IRedisInstanceInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.RedisInstanceInfo} RedisInstanceInfo instance */ - CloudFunctionInfo.create = function create(properties) { - return new CloudFunctionInfo(properties); + RedisInstanceInfo.create = function create(properties) { + return new RedisInstanceInfo(properties); }; /** - * Encodes the specified CloudFunctionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudFunctionInfo.verify|verify} messages. + * Encodes the specified RedisInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisInstanceInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo} message CloudFunctionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IRedisInstanceInfo} message RedisInstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudFunctionInfo.encode = function encode(message, writer) { + RedisInstanceInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.location != null && Object.hasOwnProperty.call(message, "location")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.location); - if (message.versionId != null && Object.hasOwnProperty.call(message, "versionId")) - writer.uint32(/* id 4, wireType 0 =*/32).int64(message.versionId); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); + if (message.primaryEndpointIp != null && Object.hasOwnProperty.call(message, "primaryEndpointIp")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.primaryEndpointIp); + if (message.readEndpointIp != null && Object.hasOwnProperty.call(message, "readEndpointIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.readEndpointIp); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); return writer; }; /** - * Encodes the specified CloudFunctionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudFunctionInfo.verify|verify} messages. + * Encodes the specified RedisInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisInstanceInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo} message CloudFunctionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IRedisInstanceInfo} message RedisInstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudFunctionInfo.encodeDelimited = function encodeDelimited(message, writer) { + RedisInstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CloudFunctionInfo message from the specified reader or buffer. + * Decodes a RedisInstanceInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo + * @returns {google.cloud.networkmanagement.v1.RedisInstanceInfo} RedisInstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudFunctionInfo.decode = function decode(reader, length) { + RedisInstanceInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CloudFunctionInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.RedisInstanceInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -12451,11 +13191,19 @@ break; } case 3: { - message.location = reader.string(); + message.networkUri = reader.string(); break; } case 4: { - message.versionId = reader.int64(); + message.primaryEndpointIp = reader.string(); + break; + } + case 5: { + message.readEndpointIp = reader.string(); + break; + } + case 6: { + message.region = reader.string(); break; } default: @@ -12467,30 +13215,30 @@ }; /** - * Decodes a CloudFunctionInfo message from the specified reader or buffer, length delimited. + * Decodes a RedisInstanceInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo + * @returns {google.cloud.networkmanagement.v1.RedisInstanceInfo} RedisInstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudFunctionInfo.decodeDelimited = function decodeDelimited(reader) { + RedisInstanceInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CloudFunctionInfo message. + * Verifies a RedisInstanceInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CloudFunctionInfo.verify = function verify(message) { + RedisInstanceInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -12499,132 +13247,136 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; - if (message.location != null && message.hasOwnProperty("location")) - if (!$util.isString(message.location)) - return "location: string expected"; - if (message.versionId != null && message.hasOwnProperty("versionId")) - if (!$util.isInteger(message.versionId) && !(message.versionId && $util.isInteger(message.versionId.low) && $util.isInteger(message.versionId.high))) - return "versionId: integer|Long expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.primaryEndpointIp != null && message.hasOwnProperty("primaryEndpointIp")) + if (!$util.isString(message.primaryEndpointIp)) + return "primaryEndpointIp: string expected"; + if (message.readEndpointIp != null && message.hasOwnProperty("readEndpointIp")) + if (!$util.isString(message.readEndpointIp)) + return "readEndpointIp: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; return null; }; /** - * Creates a CloudFunctionInfo message from a plain object. Also converts values to their respective internal types. + * Creates a RedisInstanceInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo + * @returns {google.cloud.networkmanagement.v1.RedisInstanceInfo} RedisInstanceInfo */ - CloudFunctionInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.CloudFunctionInfo) + RedisInstanceInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.RedisInstanceInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.CloudFunctionInfo(); + var message = new $root.google.cloud.networkmanagement.v1.RedisInstanceInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); - if (object.location != null) - message.location = String(object.location); - if (object.versionId != null) - if ($util.Long) - (message.versionId = $util.Long.fromValue(object.versionId)).unsigned = false; - else if (typeof object.versionId === "string") - message.versionId = parseInt(object.versionId, 10); - else if (typeof object.versionId === "number") - message.versionId = object.versionId; - else if (typeof object.versionId === "object") - message.versionId = new $util.LongBits(object.versionId.low >>> 0, object.versionId.high >>> 0).toNumber(); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.primaryEndpointIp != null) + message.primaryEndpointIp = String(object.primaryEndpointIp); + if (object.readEndpointIp != null) + message.readEndpointIp = String(object.readEndpointIp); + if (object.region != null) + message.region = String(object.region); return message; }; /** - * Creates a plain object from a CloudFunctionInfo message. Also converts values to other types if specified. + * Creates a plain object from a RedisInstanceInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1.CloudFunctionInfo} message CloudFunctionInfo + * @param {google.cloud.networkmanagement.v1.RedisInstanceInfo} message RedisInstanceInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CloudFunctionInfo.toObject = function toObject(message, options) { + RedisInstanceInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.displayName = ""; object.uri = ""; - object.location = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.versionId = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.versionId = options.longs === String ? "0" : 0; + object.networkUri = ""; + object.primaryEndpointIp = ""; + object.readEndpointIp = ""; + object.region = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.location != null && message.hasOwnProperty("location")) - object.location = message.location; - if (message.versionId != null && message.hasOwnProperty("versionId")) - if (typeof message.versionId === "number") - object.versionId = options.longs === String ? String(message.versionId) : message.versionId; - else - object.versionId = options.longs === String ? $util.Long.prototype.toString.call(message.versionId) : options.longs === Number ? new $util.LongBits(message.versionId.low >>> 0, message.versionId.high >>> 0).toNumber() : message.versionId; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.primaryEndpointIp != null && message.hasOwnProperty("primaryEndpointIp")) + object.primaryEndpointIp = message.primaryEndpointIp; + if (message.readEndpointIp != null && message.hasOwnProperty("readEndpointIp")) + object.readEndpointIp = message.readEndpointIp; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; /** - * Converts this CloudFunctionInfo to JSON. + * Converts this RedisInstanceInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @instance * @returns {Object.} JSON object */ - CloudFunctionInfo.prototype.toJSON = function toJSON() { + RedisInstanceInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CloudFunctionInfo + * Gets the default type url for RedisInstanceInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo + * @memberof google.cloud.networkmanagement.v1.RedisInstanceInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CloudFunctionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RedisInstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CloudFunctionInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.RedisInstanceInfo"; }; - return CloudFunctionInfo; + return RedisInstanceInfo; })(); - v1.CloudRunRevisionInfo = (function() { + v1.RedisClusterInfo = (function() { /** - * Properties of a CloudRunRevisionInfo. + * Properties of a RedisClusterInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface ICloudRunRevisionInfo - * @property {string|null} [displayName] CloudRunRevisionInfo displayName - * @property {string|null} [uri] CloudRunRevisionInfo uri - * @property {string|null} [location] CloudRunRevisionInfo location - * @property {string|null} [serviceUri] CloudRunRevisionInfo serviceUri + * @interface IRedisClusterInfo + * @property {string|null} [displayName] RedisClusterInfo displayName + * @property {string|null} [uri] RedisClusterInfo uri + * @property {string|null} [networkUri] RedisClusterInfo networkUri + * @property {string|null} [discoveryEndpointIpAddress] RedisClusterInfo discoveryEndpointIpAddress + * @property {string|null} [secondaryEndpointIpAddress] RedisClusterInfo secondaryEndpointIpAddress + * @property {string|null} [location] RedisClusterInfo location */ /** - * Constructs a new CloudRunRevisionInfo. + * Constructs a new RedisClusterInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a CloudRunRevisionInfo. - * @implements ICloudRunRevisionInfo + * @classdesc Represents a RedisClusterInfo. + * @implements IRedisClusterInfo * @constructor - * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IRedisClusterInfo=} [properties] Properties to set */ - function CloudRunRevisionInfo(properties) { + function RedisClusterInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -12632,100 +13384,120 @@ } /** - * CloudRunRevisionInfo displayName. + * RedisClusterInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @instance */ - CloudRunRevisionInfo.prototype.displayName = ""; + RedisClusterInfo.prototype.displayName = ""; /** - * CloudRunRevisionInfo uri. + * RedisClusterInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @instance */ - CloudRunRevisionInfo.prototype.uri = ""; + RedisClusterInfo.prototype.uri = ""; /** - * CloudRunRevisionInfo location. - * @member {string} location - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * RedisClusterInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @instance */ - CloudRunRevisionInfo.prototype.location = ""; + RedisClusterInfo.prototype.networkUri = ""; /** - * CloudRunRevisionInfo serviceUri. - * @member {string} serviceUri - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * RedisClusterInfo discoveryEndpointIpAddress. + * @member {string} discoveryEndpointIpAddress + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @instance */ - CloudRunRevisionInfo.prototype.serviceUri = ""; + RedisClusterInfo.prototype.discoveryEndpointIpAddress = ""; /** - * Creates a new CloudRunRevisionInfo instance using the specified properties. + * RedisClusterInfo secondaryEndpointIpAddress. + * @member {string} secondaryEndpointIpAddress + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo + * @instance + */ + RedisClusterInfo.prototype.secondaryEndpointIpAddress = ""; + + /** + * RedisClusterInfo location. + * @member {string} location + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo + * @instance + */ + RedisClusterInfo.prototype.location = ""; + + /** + * Creates a new RedisClusterInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo instance + * @param {google.cloud.networkmanagement.v1.IRedisClusterInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.RedisClusterInfo} RedisClusterInfo instance */ - CloudRunRevisionInfo.create = function create(properties) { - return new CloudRunRevisionInfo(properties); + RedisClusterInfo.create = function create(properties) { + return new RedisClusterInfo(properties); }; /** - * Encodes the specified CloudRunRevisionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudRunRevisionInfo.verify|verify} messages. + * Encodes the specified RedisClusterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisClusterInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo} message CloudRunRevisionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IRedisClusterInfo} message RedisClusterInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudRunRevisionInfo.encode = function encode(message, writer) { + RedisClusterInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); + if (message.discoveryEndpointIpAddress != null && Object.hasOwnProperty.call(message, "discoveryEndpointIpAddress")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.discoveryEndpointIpAddress); + if (message.secondaryEndpointIpAddress != null && Object.hasOwnProperty.call(message, "secondaryEndpointIpAddress")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.secondaryEndpointIpAddress); if (message.location != null && Object.hasOwnProperty.call(message, "location")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.location); - if (message.serviceUri != null && Object.hasOwnProperty.call(message, "serviceUri")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.serviceUri); + writer.uint32(/* id 6, wireType 2 =*/50).string(message.location); return writer; }; /** - * Encodes the specified CloudRunRevisionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudRunRevisionInfo.verify|verify} messages. + * Encodes the specified RedisClusterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RedisClusterInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo} message CloudRunRevisionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IRedisClusterInfo} message RedisClusterInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudRunRevisionInfo.encodeDelimited = function encodeDelimited(message, writer) { + RedisClusterInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CloudRunRevisionInfo message from the specified reader or buffer. + * Decodes a RedisClusterInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo + * @returns {google.cloud.networkmanagement.v1.RedisClusterInfo} RedisClusterInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudRunRevisionInfo.decode = function decode(reader, length) { + RedisClusterInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.RedisClusterInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -12737,12 +13509,20 @@ message.uri = reader.string(); break; } + case 3: { + message.networkUri = reader.string(); + break; + } case 4: { - message.location = reader.string(); + message.discoveryEndpointIpAddress = reader.string(); break; } case 5: { - message.serviceUri = reader.string(); + message.secondaryEndpointIpAddress = reader.string(); + break; + } + case 6: { + message.location = reader.string(); break; } default: @@ -12754,30 +13534,30 @@ }; /** - * Decodes a CloudRunRevisionInfo message from the specified reader or buffer, length delimited. + * Decodes a RedisClusterInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo + * @returns {google.cloud.networkmanagement.v1.RedisClusterInfo} RedisClusterInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudRunRevisionInfo.decodeDelimited = function decodeDelimited(reader) { + RedisClusterInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CloudRunRevisionInfo message. + * Verifies a RedisClusterInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CloudRunRevisionInfo.verify = function verify(message) { + RedisClusterInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -12786,118 +13566,134 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.discoveryEndpointIpAddress != null && message.hasOwnProperty("discoveryEndpointIpAddress")) + if (!$util.isString(message.discoveryEndpointIpAddress)) + return "discoveryEndpointIpAddress: string expected"; + if (message.secondaryEndpointIpAddress != null && message.hasOwnProperty("secondaryEndpointIpAddress")) + if (!$util.isString(message.secondaryEndpointIpAddress)) + return "secondaryEndpointIpAddress: string expected"; if (message.location != null && message.hasOwnProperty("location")) if (!$util.isString(message.location)) return "location: string expected"; - if (message.serviceUri != null && message.hasOwnProperty("serviceUri")) - if (!$util.isString(message.serviceUri)) - return "serviceUri: string expected"; return null; }; /** - * Creates a CloudRunRevisionInfo message from a plain object. Also converts values to their respective internal types. + * Creates a RedisClusterInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo + * @returns {google.cloud.networkmanagement.v1.RedisClusterInfo} RedisClusterInfo */ - CloudRunRevisionInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo) + RedisClusterInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.RedisClusterInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo(); + var message = new $root.google.cloud.networkmanagement.v1.RedisClusterInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.discoveryEndpointIpAddress != null) + message.discoveryEndpointIpAddress = String(object.discoveryEndpointIpAddress); + if (object.secondaryEndpointIpAddress != null) + message.secondaryEndpointIpAddress = String(object.secondaryEndpointIpAddress); if (object.location != null) message.location = String(object.location); - if (object.serviceUri != null) - message.serviceUri = String(object.serviceUri); return message; }; /** - * Creates a plain object from a CloudRunRevisionInfo message. Also converts values to other types if specified. + * Creates a plain object from a RedisClusterInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} message CloudRunRevisionInfo + * @param {google.cloud.networkmanagement.v1.RedisClusterInfo} message RedisClusterInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CloudRunRevisionInfo.toObject = function toObject(message, options) { + RedisClusterInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.displayName = ""; object.uri = ""; + object.networkUri = ""; + object.discoveryEndpointIpAddress = ""; + object.secondaryEndpointIpAddress = ""; object.location = ""; - object.serviceUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.discoveryEndpointIpAddress != null && message.hasOwnProperty("discoveryEndpointIpAddress")) + object.discoveryEndpointIpAddress = message.discoveryEndpointIpAddress; + if (message.secondaryEndpointIpAddress != null && message.hasOwnProperty("secondaryEndpointIpAddress")) + object.secondaryEndpointIpAddress = message.secondaryEndpointIpAddress; if (message.location != null && message.hasOwnProperty("location")) object.location = message.location; - if (message.serviceUri != null && message.hasOwnProperty("serviceUri")) - object.serviceUri = message.serviceUri; return object; }; /** - * Converts this CloudRunRevisionInfo to JSON. + * Converts this RedisClusterInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @instance * @returns {Object.} JSON object */ - CloudRunRevisionInfo.prototype.toJSON = function toJSON() { + RedisClusterInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CloudRunRevisionInfo + * Gets the default type url for RedisClusterInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @memberof google.cloud.networkmanagement.v1.RedisClusterInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CloudRunRevisionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RedisClusterInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CloudRunRevisionInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.RedisClusterInfo"; }; - return CloudRunRevisionInfo; + return RedisClusterInfo; })(); - v1.AppEngineVersionInfo = (function() { + v1.CloudFunctionInfo = (function() { /** - * Properties of an AppEngineVersionInfo. + * Properties of a CloudFunctionInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface IAppEngineVersionInfo - * @property {string|null} [displayName] AppEngineVersionInfo displayName - * @property {string|null} [uri] AppEngineVersionInfo uri - * @property {string|null} [runtime] AppEngineVersionInfo runtime - * @property {string|null} [environment] AppEngineVersionInfo environment + * @interface ICloudFunctionInfo + * @property {string|null} [displayName] CloudFunctionInfo displayName + * @property {string|null} [uri] CloudFunctionInfo uri + * @property {string|null} [location] CloudFunctionInfo location + * @property {number|Long|null} [versionId] CloudFunctionInfo versionId */ /** - * Constructs a new AppEngineVersionInfo. + * Constructs a new CloudFunctionInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents an AppEngineVersionInfo. - * @implements IAppEngineVersionInfo + * @classdesc Represents a CloudFunctionInfo. + * @implements ICloudFunctionInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo=} [properties] Properties to set */ - function AppEngineVersionInfo(properties) { + function CloudFunctionInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -12905,100 +13701,100 @@ } /** - * AppEngineVersionInfo displayName. + * CloudFunctionInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @instance */ - AppEngineVersionInfo.prototype.displayName = ""; + CloudFunctionInfo.prototype.displayName = ""; /** - * AppEngineVersionInfo uri. + * CloudFunctionInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @instance */ - AppEngineVersionInfo.prototype.uri = ""; + CloudFunctionInfo.prototype.uri = ""; /** - * AppEngineVersionInfo runtime. - * @member {string} runtime - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * CloudFunctionInfo location. + * @member {string} location + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @instance */ - AppEngineVersionInfo.prototype.runtime = ""; + CloudFunctionInfo.prototype.location = ""; /** - * AppEngineVersionInfo environment. - * @member {string} environment - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * CloudFunctionInfo versionId. + * @member {number|Long} versionId + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @instance */ - AppEngineVersionInfo.prototype.environment = ""; + CloudFunctionInfo.prototype.versionId = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * Creates a new AppEngineVersionInfo instance using the specified properties. + * Creates a new CloudFunctionInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static - * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo instance + * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo instance */ - AppEngineVersionInfo.create = function create(properties) { - return new AppEngineVersionInfo(properties); + CloudFunctionInfo.create = function create(properties) { + return new CloudFunctionInfo(properties); }; /** - * Encodes the specified AppEngineVersionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.AppEngineVersionInfo.verify|verify} messages. + * Encodes the specified CloudFunctionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudFunctionInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static - * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo} message AppEngineVersionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo} message CloudFunctionInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - AppEngineVersionInfo.encode = function encode(message, writer) { + CloudFunctionInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.runtime != null && Object.hasOwnProperty.call(message, "runtime")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.runtime); - if (message.environment != null && Object.hasOwnProperty.call(message, "environment")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.environment); + if (message.location != null && Object.hasOwnProperty.call(message, "location")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.location); + if (message.versionId != null && Object.hasOwnProperty.call(message, "versionId")) + writer.uint32(/* id 4, wireType 0 =*/32).int64(message.versionId); return writer; }; /** - * Encodes the specified AppEngineVersionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.AppEngineVersionInfo.verify|verify} messages. + * Encodes the specified CloudFunctionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudFunctionInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static - * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo} message AppEngineVersionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICloudFunctionInfo} message CloudFunctionInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - AppEngineVersionInfo.encodeDelimited = function encodeDelimited(message, writer) { + CloudFunctionInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an AppEngineVersionInfo message from the specified reader or buffer. + * Decodes a CloudFunctionInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo + * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - AppEngineVersionInfo.decode = function decode(reader, length) { + CloudFunctionInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CloudFunctionInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -13011,11 +13807,11 @@ break; } case 3: { - message.runtime = reader.string(); + message.location = reader.string(); break; } case 4: { - message.environment = reader.string(); + message.versionId = reader.int64(); break; } default: @@ -13027,30 +13823,30 @@ }; /** - * Decodes an AppEngineVersionInfo message from the specified reader or buffer, length delimited. + * Decodes a CloudFunctionInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo + * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - AppEngineVersionInfo.decodeDelimited = function decodeDelimited(reader) { + CloudFunctionInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an AppEngineVersionInfo message. + * Verifies a CloudFunctionInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - AppEngineVersionInfo.verify = function verify(message) { + CloudFunctionInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -13059,117 +13855,132 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; - if (message.runtime != null && message.hasOwnProperty("runtime")) - if (!$util.isString(message.runtime)) - return "runtime: string expected"; - if (message.environment != null && message.hasOwnProperty("environment")) - if (!$util.isString(message.environment)) - return "environment: string expected"; + if (message.location != null && message.hasOwnProperty("location")) + if (!$util.isString(message.location)) + return "location: string expected"; + if (message.versionId != null && message.hasOwnProperty("versionId")) + if (!$util.isInteger(message.versionId) && !(message.versionId && $util.isInteger(message.versionId.low) && $util.isInteger(message.versionId.high))) + return "versionId: integer|Long expected"; return null; }; /** - * Creates an AppEngineVersionInfo message from a plain object. Also converts values to their respective internal types. + * Creates a CloudFunctionInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo + * @returns {google.cloud.networkmanagement.v1.CloudFunctionInfo} CloudFunctionInfo */ - AppEngineVersionInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo) + CloudFunctionInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.CloudFunctionInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo(); + var message = new $root.google.cloud.networkmanagement.v1.CloudFunctionInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); - if (object.runtime != null) - message.runtime = String(object.runtime); - if (object.environment != null) - message.environment = String(object.environment); + if (object.location != null) + message.location = String(object.location); + if (object.versionId != null) + if ($util.Long) + (message.versionId = $util.Long.fromValue(object.versionId)).unsigned = false; + else if (typeof object.versionId === "string") + message.versionId = parseInt(object.versionId, 10); + else if (typeof object.versionId === "number") + message.versionId = object.versionId; + else if (typeof object.versionId === "object") + message.versionId = new $util.LongBits(object.versionId.low >>> 0, object.versionId.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from an AppEngineVersionInfo message. Also converts values to other types if specified. + * Creates a plain object from a CloudFunctionInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static - * @param {google.cloud.networkmanagement.v1.AppEngineVersionInfo} message AppEngineVersionInfo + * @param {google.cloud.networkmanagement.v1.CloudFunctionInfo} message CloudFunctionInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - AppEngineVersionInfo.toObject = function toObject(message, options) { + CloudFunctionInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.displayName = ""; object.uri = ""; - object.runtime = ""; - object.environment = ""; + object.location = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.versionId = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.versionId = options.longs === String ? "0" : 0; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.runtime != null && message.hasOwnProperty("runtime")) - object.runtime = message.runtime; - if (message.environment != null && message.hasOwnProperty("environment")) - object.environment = message.environment; + if (message.location != null && message.hasOwnProperty("location")) + object.location = message.location; + if (message.versionId != null && message.hasOwnProperty("versionId")) + if (typeof message.versionId === "number") + object.versionId = options.longs === String ? String(message.versionId) : message.versionId; + else + object.versionId = options.longs === String ? $util.Long.prototype.toString.call(message.versionId) : options.longs === Number ? new $util.LongBits(message.versionId.low >>> 0, message.versionId.high >>> 0).toNumber() : message.versionId; return object; }; /** - * Converts this AppEngineVersionInfo to JSON. + * Converts this CloudFunctionInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @instance * @returns {Object.} JSON object */ - AppEngineVersionInfo.prototype.toJSON = function toJSON() { + CloudFunctionInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for AppEngineVersionInfo + * Gets the default type url for CloudFunctionInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @memberof google.cloud.networkmanagement.v1.CloudFunctionInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - AppEngineVersionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CloudFunctionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.AppEngineVersionInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CloudFunctionInfo"; }; - return AppEngineVersionInfo; + return CloudFunctionInfo; })(); - v1.VpcConnectorInfo = (function() { + v1.CloudRunRevisionInfo = (function() { /** - * Properties of a VpcConnectorInfo. + * Properties of a CloudRunRevisionInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface IVpcConnectorInfo - * @property {string|null} [displayName] VpcConnectorInfo displayName - * @property {string|null} [uri] VpcConnectorInfo uri - * @property {string|null} [location] VpcConnectorInfo location + * @interface ICloudRunRevisionInfo + * @property {string|null} [displayName] CloudRunRevisionInfo displayName + * @property {string|null} [uri] CloudRunRevisionInfo uri + * @property {string|null} [location] CloudRunRevisionInfo location + * @property {string|null} [serviceUri] CloudRunRevisionInfo serviceUri */ /** - * Constructs a new VpcConnectorInfo. + * Constructs a new CloudRunRevisionInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a VpcConnectorInfo. - * @implements IVpcConnectorInfo + * @classdesc Represents a CloudRunRevisionInfo. + * @implements ICloudRunRevisionInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo=} [properties] Properties to set */ - function VpcConnectorInfo(properties) { + function CloudRunRevisionInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13177,51 +13988,59 @@ } /** - * VpcConnectorInfo displayName. + * CloudRunRevisionInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @instance */ - VpcConnectorInfo.prototype.displayName = ""; + CloudRunRevisionInfo.prototype.displayName = ""; /** - * VpcConnectorInfo uri. + * CloudRunRevisionInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @instance */ - VpcConnectorInfo.prototype.uri = ""; + CloudRunRevisionInfo.prototype.uri = ""; /** - * VpcConnectorInfo location. + * CloudRunRevisionInfo location. * @member {string} location - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @instance */ - VpcConnectorInfo.prototype.location = ""; + CloudRunRevisionInfo.prototype.location = ""; /** - * Creates a new VpcConnectorInfo instance using the specified properties. + * CloudRunRevisionInfo serviceUri. + * @member {string} serviceUri + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo + * @instance + */ + CloudRunRevisionInfo.prototype.serviceUri = ""; + + /** + * Creates a new CloudRunRevisionInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static - * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo instance + * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo instance */ - VpcConnectorInfo.create = function create(properties) { - return new VpcConnectorInfo(properties); + CloudRunRevisionInfo.create = function create(properties) { + return new CloudRunRevisionInfo(properties); }; /** - * Encodes the specified VpcConnectorInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.VpcConnectorInfo.verify|verify} messages. + * Encodes the specified CloudRunRevisionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudRunRevisionInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static - * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo} message VpcConnectorInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo} message CloudRunRevisionInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpcConnectorInfo.encode = function encode(message, writer) { + CloudRunRevisionInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) @@ -13229,38 +14048,40 @@ if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); if (message.location != null && Object.hasOwnProperty.call(message, "location")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.location); + writer.uint32(/* id 4, wireType 2 =*/34).string(message.location); + if (message.serviceUri != null && Object.hasOwnProperty.call(message, "serviceUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.serviceUri); return writer; }; /** - * Encodes the specified VpcConnectorInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.VpcConnectorInfo.verify|verify} messages. + * Encodes the specified CloudRunRevisionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CloudRunRevisionInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static - * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo} message VpcConnectorInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICloudRunRevisionInfo} message CloudRunRevisionInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpcConnectorInfo.encodeDelimited = function encodeDelimited(message, writer) { + CloudRunRevisionInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a VpcConnectorInfo message from the specified reader or buffer. + * Decodes a CloudRunRevisionInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo + * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpcConnectorInfo.decode = function decode(reader, length) { + CloudRunRevisionInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.VpcConnectorInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -13272,10 +14093,14 @@ message.uri = reader.string(); break; } - case 3: { + case 4: { message.location = reader.string(); break; } + case 5: { + message.serviceUri = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -13285,30 +14110,30 @@ }; /** - * Decodes a VpcConnectorInfo message from the specified reader or buffer, length delimited. + * Decodes a CloudRunRevisionInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo + * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpcConnectorInfo.decodeDelimited = function decodeDelimited(reader) { + CloudRunRevisionInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a VpcConnectorInfo message. + * Verifies a CloudRunRevisionInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - VpcConnectorInfo.verify = function verify(message) { + CloudRunRevisionInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -13320,40 +14145,45 @@ if (message.location != null && message.hasOwnProperty("location")) if (!$util.isString(message.location)) return "location: string expected"; + if (message.serviceUri != null && message.hasOwnProperty("serviceUri")) + if (!$util.isString(message.serviceUri)) + return "serviceUri: string expected"; return null; }; /** - * Creates a VpcConnectorInfo message from a plain object. Also converts values to their respective internal types. + * Creates a CloudRunRevisionInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo + * @returns {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} CloudRunRevisionInfo */ - VpcConnectorInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.VpcConnectorInfo) + CloudRunRevisionInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.VpcConnectorInfo(); + var message = new $root.google.cloud.networkmanagement.v1.CloudRunRevisionInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); if (object.location != null) message.location = String(object.location); + if (object.serviceUri != null) + message.serviceUri = String(object.serviceUri); return message; }; /** - * Creates a plain object from a VpcConnectorInfo message. Also converts values to other types if specified. + * Creates a plain object from a CloudRunRevisionInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static - * @param {google.cloud.networkmanagement.v1.VpcConnectorInfo} message VpcConnectorInfo + * @param {google.cloud.networkmanagement.v1.CloudRunRevisionInfo} message CloudRunRevisionInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - VpcConnectorInfo.toObject = function toObject(message, options) { + CloudRunRevisionInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -13361,6 +14191,7 @@ object.displayName = ""; object.uri = ""; object.location = ""; + object.serviceUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -13368,68 +14199,61 @@ object.uri = message.uri; if (message.location != null && message.hasOwnProperty("location")) object.location = message.location; + if (message.serviceUri != null && message.hasOwnProperty("serviceUri")) + object.serviceUri = message.serviceUri; return object; }; /** - * Converts this VpcConnectorInfo to JSON. + * Converts this CloudRunRevisionInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @instance * @returns {Object.} JSON object */ - VpcConnectorInfo.prototype.toJSON = function toJSON() { + CloudRunRevisionInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for VpcConnectorInfo + * Gets the default type url for CloudRunRevisionInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @memberof google.cloud.networkmanagement.v1.CloudRunRevisionInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - VpcConnectorInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CloudRunRevisionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.VpcConnectorInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CloudRunRevisionInfo"; }; - return VpcConnectorInfo; + return CloudRunRevisionInfo; })(); - v1.NatInfo = (function() { + v1.AppEngineVersionInfo = (function() { /** - * Properties of a NatInfo. + * Properties of an AppEngineVersionInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface INatInfo - * @property {google.cloud.networkmanagement.v1.NatInfo.Type|null} [type] NatInfo type - * @property {string|null} [protocol] NatInfo protocol - * @property {string|null} [networkUri] NatInfo networkUri - * @property {string|null} [oldSourceIp] NatInfo oldSourceIp - * @property {string|null} [newSourceIp] NatInfo newSourceIp - * @property {string|null} [oldDestinationIp] NatInfo oldDestinationIp - * @property {string|null} [newDestinationIp] NatInfo newDestinationIp - * @property {number|null} [oldSourcePort] NatInfo oldSourcePort - * @property {number|null} [newSourcePort] NatInfo newSourcePort - * @property {number|null} [oldDestinationPort] NatInfo oldDestinationPort - * @property {number|null} [newDestinationPort] NatInfo newDestinationPort - * @property {string|null} [routerUri] NatInfo routerUri - * @property {string|null} [natGatewayName] NatInfo natGatewayName + * @interface IAppEngineVersionInfo + * @property {string|null} [displayName] AppEngineVersionInfo displayName + * @property {string|null} [uri] AppEngineVersionInfo uri + * @property {string|null} [runtime] AppEngineVersionInfo runtime + * @property {string|null} [environment] AppEngineVersionInfo environment */ /** - * Constructs a new NatInfo. + * Constructs a new AppEngineVersionInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a NatInfo. - * @implements INatInfo + * @classdesc Represents an AppEngineVersionInfo. + * @implements IAppEngineVersionInfo * @constructor - * @param {google.cloud.networkmanagement.v1.INatInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo=} [properties] Properties to set */ - function NatInfo(properties) { + function AppEngineVersionInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13437,243 +14261,117 @@ } /** - * NatInfo type. - * @member {google.cloud.networkmanagement.v1.NatInfo.Type} type - * @memberof google.cloud.networkmanagement.v1.NatInfo + * AppEngineVersionInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @instance */ - NatInfo.prototype.type = 0; + AppEngineVersionInfo.prototype.displayName = ""; /** - * NatInfo protocol. - * @member {string} protocol - * @memberof google.cloud.networkmanagement.v1.NatInfo + * AppEngineVersionInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @instance */ - NatInfo.prototype.protocol = ""; + AppEngineVersionInfo.prototype.uri = ""; /** - * NatInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1.NatInfo + * AppEngineVersionInfo runtime. + * @member {string} runtime + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @instance */ - NatInfo.prototype.networkUri = ""; + AppEngineVersionInfo.prototype.runtime = ""; /** - * NatInfo oldSourceIp. - * @member {string} oldSourceIp - * @memberof google.cloud.networkmanagement.v1.NatInfo + * AppEngineVersionInfo environment. + * @member {string} environment + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @instance */ - NatInfo.prototype.oldSourceIp = ""; + AppEngineVersionInfo.prototype.environment = ""; /** - * NatInfo newSourceIp. - * @member {string} newSourceIp - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance + * Creates a new AppEngineVersionInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @static + * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo instance */ - NatInfo.prototype.newSourceIp = ""; + AppEngineVersionInfo.create = function create(properties) { + return new AppEngineVersionInfo(properties); + }; /** - * NatInfo oldDestinationIp. - * @member {string} oldDestinationIp - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance + * Encodes the specified AppEngineVersionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.AppEngineVersionInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo + * @static + * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo} message AppEngineVersionInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - NatInfo.prototype.oldDestinationIp = ""; - - /** - * NatInfo newDestinationIp. - * @member {string} newDestinationIp - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.newDestinationIp = ""; - - /** - * NatInfo oldSourcePort. - * @member {number} oldSourcePort - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.oldSourcePort = 0; - - /** - * NatInfo newSourcePort. - * @member {number} newSourcePort - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.newSourcePort = 0; - - /** - * NatInfo oldDestinationPort. - * @member {number} oldDestinationPort - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.oldDestinationPort = 0; - - /** - * NatInfo newDestinationPort. - * @member {number} newDestinationPort - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.newDestinationPort = 0; - - /** - * NatInfo routerUri. - * @member {string} routerUri - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.routerUri = ""; - - /** - * NatInfo natGatewayName. - * @member {string} natGatewayName - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @instance - */ - NatInfo.prototype.natGatewayName = ""; - - /** - * Creates a new NatInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @static - * @param {google.cloud.networkmanagement.v1.INatInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo instance - */ - NatInfo.create = function create(properties) { - return new NatInfo(properties); - }; - - /** - * Encodes the specified NatInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.NatInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1.NatInfo - * @static - * @param {google.cloud.networkmanagement.v1.INatInfo} message NatInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - NatInfo.encode = function encode(message, writer) { + AppEngineVersionInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.type); - if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.protocol); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); - if (message.oldSourceIp != null && Object.hasOwnProperty.call(message, "oldSourceIp")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.oldSourceIp); - if (message.newSourceIp != null && Object.hasOwnProperty.call(message, "newSourceIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.newSourceIp); - if (message.oldDestinationIp != null && Object.hasOwnProperty.call(message, "oldDestinationIp")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.oldDestinationIp); - if (message.newDestinationIp != null && Object.hasOwnProperty.call(message, "newDestinationIp")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.newDestinationIp); - if (message.oldSourcePort != null && Object.hasOwnProperty.call(message, "oldSourcePort")) - writer.uint32(/* id 8, wireType 0 =*/64).int32(message.oldSourcePort); - if (message.newSourcePort != null && Object.hasOwnProperty.call(message, "newSourcePort")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.newSourcePort); - if (message.oldDestinationPort != null && Object.hasOwnProperty.call(message, "oldDestinationPort")) - writer.uint32(/* id 10, wireType 0 =*/80).int32(message.oldDestinationPort); - if (message.newDestinationPort != null && Object.hasOwnProperty.call(message, "newDestinationPort")) - writer.uint32(/* id 11, wireType 0 =*/88).int32(message.newDestinationPort); - if (message.routerUri != null && Object.hasOwnProperty.call(message, "routerUri")) - writer.uint32(/* id 12, wireType 2 =*/98).string(message.routerUri); - if (message.natGatewayName != null && Object.hasOwnProperty.call(message, "natGatewayName")) - writer.uint32(/* id 13, wireType 2 =*/106).string(message.natGatewayName); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.runtime != null && Object.hasOwnProperty.call(message, "runtime")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.runtime); + if (message.environment != null && Object.hasOwnProperty.call(message, "environment")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.environment); return writer; }; /** - * Encodes the specified NatInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.NatInfo.verify|verify} messages. + * Encodes the specified AppEngineVersionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.AppEngineVersionInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static - * @param {google.cloud.networkmanagement.v1.INatInfo} message NatInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IAppEngineVersionInfo} message AppEngineVersionInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NatInfo.encodeDelimited = function encodeDelimited(message, writer) { + AppEngineVersionInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a NatInfo message from the specified reader or buffer. + * Decodes an AppEngineVersionInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo + * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NatInfo.decode = function decode(reader, length) { + AppEngineVersionInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.NatInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.type = reader.int32(); + message.displayName = reader.string(); break; } case 2: { - message.protocol = reader.string(); + message.uri = reader.string(); break; } case 3: { - message.networkUri = reader.string(); + message.runtime = reader.string(); break; } case 4: { - message.oldSourceIp = reader.string(); - break; - } - case 5: { - message.newSourceIp = reader.string(); - break; - } - case 6: { - message.oldDestinationIp = reader.string(); - break; - } - case 7: { - message.newDestinationIp = reader.string(); - break; - } - case 8: { - message.oldSourcePort = reader.int32(); - break; - } - case 9: { - message.newSourcePort = reader.int32(); - break; - } - case 10: { - message.oldDestinationPort = reader.int32(); - break; - } - case 11: { - message.newDestinationPort = reader.int32(); - break; - } - case 12: { - message.routerUri = reader.string(); - break; - } - case 13: { - message.natGatewayName = reader.string(); + message.environment = reader.string(); break; } default: @@ -13685,283 +14383,149 @@ }; /** - * Decodes a NatInfo message from the specified reader or buffer, length delimited. + * Decodes an AppEngineVersionInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo + * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NatInfo.decodeDelimited = function decodeDelimited(reader) { + AppEngineVersionInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a NatInfo message. + * Verifies an AppEngineVersionInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - NatInfo.verify = function verify(message) { + AppEngineVersionInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.type != null && message.hasOwnProperty("type")) - switch (message.type) { - default: - return "type: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - break; - } - if (message.protocol != null && message.hasOwnProperty("protocol")) - if (!$util.isString(message.protocol)) - return "protocol: string expected"; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - if (!$util.isString(message.networkUri)) - return "networkUri: string expected"; - if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) - if (!$util.isString(message.oldSourceIp)) - return "oldSourceIp: string expected"; - if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) - if (!$util.isString(message.newSourceIp)) - return "newSourceIp: string expected"; - if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) - if (!$util.isString(message.oldDestinationIp)) - return "oldDestinationIp: string expected"; - if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) - if (!$util.isString(message.newDestinationIp)) - return "newDestinationIp: string expected"; - if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) - if (!$util.isInteger(message.oldSourcePort)) - return "oldSourcePort: integer expected"; - if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) - if (!$util.isInteger(message.newSourcePort)) - return "newSourcePort: integer expected"; - if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) - if (!$util.isInteger(message.oldDestinationPort)) - return "oldDestinationPort: integer expected"; - if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) - if (!$util.isInteger(message.newDestinationPort)) - return "newDestinationPort: integer expected"; - if (message.routerUri != null && message.hasOwnProperty("routerUri")) - if (!$util.isString(message.routerUri)) - return "routerUri: string expected"; - if (message.natGatewayName != null && message.hasOwnProperty("natGatewayName")) - if (!$util.isString(message.natGatewayName)) - return "natGatewayName: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.runtime != null && message.hasOwnProperty("runtime")) + if (!$util.isString(message.runtime)) + return "runtime: string expected"; + if (message.environment != null && message.hasOwnProperty("environment")) + if (!$util.isString(message.environment)) + return "environment: string expected"; return null; }; /** - * Creates a NatInfo message from a plain object. Also converts values to their respective internal types. + * Creates an AppEngineVersionInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo + * @returns {google.cloud.networkmanagement.v1.AppEngineVersionInfo} AppEngineVersionInfo */ - NatInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.NatInfo) + AppEngineVersionInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.NatInfo(); - switch (object.type) { - default: - if (typeof object.type === "number") { - message.type = object.type; - break; - } - break; - case "TYPE_UNSPECIFIED": - case 0: - message.type = 0; - break; - case "INTERNAL_TO_EXTERNAL": - case 1: - message.type = 1; - break; - case "EXTERNAL_TO_INTERNAL": - case 2: - message.type = 2; - break; - case "CLOUD_NAT": - case 3: - message.type = 3; - break; - case "PRIVATE_SERVICE_CONNECT": - case 4: - message.type = 4; - break; - } - if (object.protocol != null) - message.protocol = String(object.protocol); - if (object.networkUri != null) - message.networkUri = String(object.networkUri); - if (object.oldSourceIp != null) - message.oldSourceIp = String(object.oldSourceIp); - if (object.newSourceIp != null) - message.newSourceIp = String(object.newSourceIp); - if (object.oldDestinationIp != null) - message.oldDestinationIp = String(object.oldDestinationIp); - if (object.newDestinationIp != null) - message.newDestinationIp = String(object.newDestinationIp); - if (object.oldSourcePort != null) - message.oldSourcePort = object.oldSourcePort | 0; - if (object.newSourcePort != null) - message.newSourcePort = object.newSourcePort | 0; - if (object.oldDestinationPort != null) - message.oldDestinationPort = object.oldDestinationPort | 0; - if (object.newDestinationPort != null) - message.newDestinationPort = object.newDestinationPort | 0; - if (object.routerUri != null) - message.routerUri = String(object.routerUri); - if (object.natGatewayName != null) - message.natGatewayName = String(object.natGatewayName); + var message = new $root.google.cloud.networkmanagement.v1.AppEngineVersionInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.runtime != null) + message.runtime = String(object.runtime); + if (object.environment != null) + message.environment = String(object.environment); return message; }; /** - * Creates a plain object from a NatInfo message. Also converts values to other types if specified. + * Creates a plain object from an AppEngineVersionInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static - * @param {google.cloud.networkmanagement.v1.NatInfo} message NatInfo + * @param {google.cloud.networkmanagement.v1.AppEngineVersionInfo} message AppEngineVersionInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - NatInfo.toObject = function toObject(message, options) { + AppEngineVersionInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.type = options.enums === String ? "TYPE_UNSPECIFIED" : 0; - object.protocol = ""; - object.networkUri = ""; - object.oldSourceIp = ""; - object.newSourceIp = ""; - object.oldDestinationIp = ""; - object.newDestinationIp = ""; - object.oldSourcePort = 0; - object.newSourcePort = 0; - object.oldDestinationPort = 0; - object.newDestinationPort = 0; - object.routerUri = ""; - object.natGatewayName = ""; + object.displayName = ""; + object.uri = ""; + object.runtime = ""; + object.environment = ""; } - if (message.type != null && message.hasOwnProperty("type")) - object.type = options.enums === String ? $root.google.cloud.networkmanagement.v1.NatInfo.Type[message.type] === undefined ? message.type : $root.google.cloud.networkmanagement.v1.NatInfo.Type[message.type] : message.type; - if (message.protocol != null && message.hasOwnProperty("protocol")) - object.protocol = message.protocol; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - object.networkUri = message.networkUri; - if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) - object.oldSourceIp = message.oldSourceIp; - if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) - object.newSourceIp = message.newSourceIp; - if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) - object.oldDestinationIp = message.oldDestinationIp; - if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) - object.newDestinationIp = message.newDestinationIp; - if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) - object.oldSourcePort = message.oldSourcePort; - if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) - object.newSourcePort = message.newSourcePort; - if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) - object.oldDestinationPort = message.oldDestinationPort; - if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) - object.newDestinationPort = message.newDestinationPort; - if (message.routerUri != null && message.hasOwnProperty("routerUri")) - object.routerUri = message.routerUri; - if (message.natGatewayName != null && message.hasOwnProperty("natGatewayName")) - object.natGatewayName = message.natGatewayName; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.runtime != null && message.hasOwnProperty("runtime")) + object.runtime = message.runtime; + if (message.environment != null && message.hasOwnProperty("environment")) + object.environment = message.environment; return object; }; /** - * Converts this NatInfo to JSON. + * Converts this AppEngineVersionInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @instance * @returns {Object.} JSON object */ - NatInfo.prototype.toJSON = function toJSON() { + AppEngineVersionInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for NatInfo + * Gets the default type url for AppEngineVersionInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.NatInfo + * @memberof google.cloud.networkmanagement.v1.AppEngineVersionInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - NatInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + AppEngineVersionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.NatInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.AppEngineVersionInfo"; }; - /** - * Type enum. - * @name google.cloud.networkmanagement.v1.NatInfo.Type - * @enum {number} - * @property {number} TYPE_UNSPECIFIED=0 TYPE_UNSPECIFIED value - * @property {number} INTERNAL_TO_EXTERNAL=1 INTERNAL_TO_EXTERNAL value - * @property {number} EXTERNAL_TO_INTERNAL=2 EXTERNAL_TO_INTERNAL value - * @property {number} CLOUD_NAT=3 CLOUD_NAT value - * @property {number} PRIVATE_SERVICE_CONNECT=4 PRIVATE_SERVICE_CONNECT value - */ - NatInfo.Type = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "INTERNAL_TO_EXTERNAL"] = 1; - values[valuesById[2] = "EXTERNAL_TO_INTERNAL"] = 2; - values[valuesById[3] = "CLOUD_NAT"] = 3; - values[valuesById[4] = "PRIVATE_SERVICE_CONNECT"] = 4; - return values; - })(); - - return NatInfo; + return AppEngineVersionInfo; })(); - v1.ProxyConnectionInfo = (function() { + v1.VpcConnectorInfo = (function() { /** - * Properties of a ProxyConnectionInfo. + * Properties of a VpcConnectorInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface IProxyConnectionInfo - * @property {string|null} [protocol] ProxyConnectionInfo protocol - * @property {string|null} [oldSourceIp] ProxyConnectionInfo oldSourceIp - * @property {string|null} [newSourceIp] ProxyConnectionInfo newSourceIp - * @property {string|null} [oldDestinationIp] ProxyConnectionInfo oldDestinationIp - * @property {string|null} [newDestinationIp] ProxyConnectionInfo newDestinationIp - * @property {number|null} [oldSourcePort] ProxyConnectionInfo oldSourcePort - * @property {number|null} [newSourcePort] ProxyConnectionInfo newSourcePort - * @property {number|null} [oldDestinationPort] ProxyConnectionInfo oldDestinationPort - * @property {number|null} [newDestinationPort] ProxyConnectionInfo newDestinationPort - * @property {string|null} [subnetUri] ProxyConnectionInfo subnetUri - * @property {string|null} [networkUri] ProxyConnectionInfo networkUri + * @interface IVpcConnectorInfo + * @property {string|null} [displayName] VpcConnectorInfo displayName + * @property {string|null} [uri] VpcConnectorInfo uri + * @property {string|null} [location] VpcConnectorInfo location */ /** - * Constructs a new ProxyConnectionInfo. + * Constructs a new VpcConnectorInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a ProxyConnectionInfo. - * @implements IProxyConnectionInfo + * @classdesc Represents a VpcConnectorInfo. + * @implements IVpcConnectorInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo=} [properties] Properties to set */ - function ProxyConnectionInfo(properties) { + function VpcConnectorInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13969,215 +14533,103 @@ } /** - * ProxyConnectionInfo protocol. - * @member {string} protocol - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.protocol = ""; - - /** - * ProxyConnectionInfo oldSourceIp. - * @member {string} oldSourceIp - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * VpcConnectorInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @instance */ - ProxyConnectionInfo.prototype.oldSourceIp = ""; + VpcConnectorInfo.prototype.displayName = ""; /** - * ProxyConnectionInfo newSourceIp. - * @member {string} newSourceIp - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * VpcConnectorInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @instance */ - ProxyConnectionInfo.prototype.newSourceIp = ""; + VpcConnectorInfo.prototype.uri = ""; /** - * ProxyConnectionInfo oldDestinationIp. - * @member {string} oldDestinationIp - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * VpcConnectorInfo location. + * @member {string} location + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @instance */ - ProxyConnectionInfo.prototype.oldDestinationIp = ""; + VpcConnectorInfo.prototype.location = ""; /** - * ProxyConnectionInfo newDestinationIp. - * @member {string} newDestinationIp - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance + * Creates a new VpcConnectorInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @static + * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo instance */ - ProxyConnectionInfo.prototype.newDestinationIp = ""; + VpcConnectorInfo.create = function create(properties) { + return new VpcConnectorInfo(properties); + }; /** - * ProxyConnectionInfo oldSourcePort. - * @member {number} oldSourcePort - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance + * Encodes the specified VpcConnectorInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.VpcConnectorInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo + * @static + * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo} message VpcConnectorInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - ProxyConnectionInfo.prototype.oldSourcePort = 0; + VpcConnectorInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.location != null && Object.hasOwnProperty.call(message, "location")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.location); + return writer; + }; /** - * ProxyConnectionInfo newSourcePort. - * @member {number} newSourcePort - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.newSourcePort = 0; - - /** - * ProxyConnectionInfo oldDestinationPort. - * @member {number} oldDestinationPort - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.oldDestinationPort = 0; - - /** - * ProxyConnectionInfo newDestinationPort. - * @member {number} newDestinationPort - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.newDestinationPort = 0; - - /** - * ProxyConnectionInfo subnetUri. - * @member {string} subnetUri - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.subnetUri = ""; - - /** - * ProxyConnectionInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @instance - */ - ProxyConnectionInfo.prototype.networkUri = ""; - - /** - * Creates a new ProxyConnectionInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @static - * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo instance - */ - ProxyConnectionInfo.create = function create(properties) { - return new ProxyConnectionInfo(properties); - }; - - /** - * Encodes the specified ProxyConnectionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.ProxyConnectionInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo - * @static - * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo} message ProxyConnectionInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ProxyConnectionInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.protocol); - if (message.oldSourceIp != null && Object.hasOwnProperty.call(message, "oldSourceIp")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.oldSourceIp); - if (message.newSourceIp != null && Object.hasOwnProperty.call(message, "newSourceIp")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.newSourceIp); - if (message.oldDestinationIp != null && Object.hasOwnProperty.call(message, "oldDestinationIp")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.oldDestinationIp); - if (message.newDestinationIp != null && Object.hasOwnProperty.call(message, "newDestinationIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.newDestinationIp); - if (message.oldSourcePort != null && Object.hasOwnProperty.call(message, "oldSourcePort")) - writer.uint32(/* id 6, wireType 0 =*/48).int32(message.oldSourcePort); - if (message.newSourcePort != null && Object.hasOwnProperty.call(message, "newSourcePort")) - writer.uint32(/* id 7, wireType 0 =*/56).int32(message.newSourcePort); - if (message.oldDestinationPort != null && Object.hasOwnProperty.call(message, "oldDestinationPort")) - writer.uint32(/* id 8, wireType 0 =*/64).int32(message.oldDestinationPort); - if (message.newDestinationPort != null && Object.hasOwnProperty.call(message, "newDestinationPort")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.newDestinationPort); - if (message.subnetUri != null && Object.hasOwnProperty.call(message, "subnetUri")) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.subnetUri); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 11, wireType 2 =*/90).string(message.networkUri); - return writer; - }; - - /** - * Encodes the specified ProxyConnectionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ProxyConnectionInfo.verify|verify} messages. + * Encodes the specified VpcConnectorInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.VpcConnectorInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static - * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo} message ProxyConnectionInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IVpcConnectorInfo} message VpcConnectorInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ProxyConnectionInfo.encodeDelimited = function encodeDelimited(message, writer) { + VpcConnectorInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ProxyConnectionInfo message from the specified reader or buffer. + * Decodes a VpcConnectorInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo + * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ProxyConnectionInfo.decode = function decode(reader, length) { + VpcConnectorInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.VpcConnectorInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.protocol = reader.string(); + message.displayName = reader.string(); break; } case 2: { - message.oldSourceIp = reader.string(); + message.uri = reader.string(); break; } case 3: { - message.newSourceIp = reader.string(); - break; - } - case 4: { - message.oldDestinationIp = reader.string(); - break; - } - case 5: { - message.newDestinationIp = reader.string(); - break; - } - case 6: { - message.oldSourcePort = reader.int32(); - break; - } - case 7: { - message.newSourcePort = reader.int32(); - break; - } - case 8: { - message.oldDestinationPort = reader.int32(); - break; - } - case 9: { - message.newDestinationPort = reader.int32(); - break; - } - case 10: { - message.subnetUri = reader.string(); - break; - } - case 11: { - message.networkUri = reader.string(); + message.location = reader.string(); break; } default: @@ -14189,212 +14641,151 @@ }; /** - * Decodes a ProxyConnectionInfo message from the specified reader or buffer, length delimited. + * Decodes a VpcConnectorInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo + * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ProxyConnectionInfo.decodeDelimited = function decodeDelimited(reader) { + VpcConnectorInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ProxyConnectionInfo message. + * Verifies a VpcConnectorInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ProxyConnectionInfo.verify = function verify(message) { + VpcConnectorInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.protocol != null && message.hasOwnProperty("protocol")) - if (!$util.isString(message.protocol)) - return "protocol: string expected"; - if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) - if (!$util.isString(message.oldSourceIp)) - return "oldSourceIp: string expected"; - if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) - if (!$util.isString(message.newSourceIp)) - return "newSourceIp: string expected"; - if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) - if (!$util.isString(message.oldDestinationIp)) - return "oldDestinationIp: string expected"; - if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) - if (!$util.isString(message.newDestinationIp)) - return "newDestinationIp: string expected"; - if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) - if (!$util.isInteger(message.oldSourcePort)) - return "oldSourcePort: integer expected"; - if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) - if (!$util.isInteger(message.newSourcePort)) - return "newSourcePort: integer expected"; - if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) - if (!$util.isInteger(message.oldDestinationPort)) - return "oldDestinationPort: integer expected"; - if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) - if (!$util.isInteger(message.newDestinationPort)) - return "newDestinationPort: integer expected"; - if (message.subnetUri != null && message.hasOwnProperty("subnetUri")) - if (!$util.isString(message.subnetUri)) - return "subnetUri: string expected"; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - if (!$util.isString(message.networkUri)) - return "networkUri: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.location != null && message.hasOwnProperty("location")) + if (!$util.isString(message.location)) + return "location: string expected"; return null; }; /** - * Creates a ProxyConnectionInfo message from a plain object. Also converts values to their respective internal types. + * Creates a VpcConnectorInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo + * @returns {google.cloud.networkmanagement.v1.VpcConnectorInfo} VpcConnectorInfo */ - ProxyConnectionInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo) + VpcConnectorInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.VpcConnectorInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo(); - if (object.protocol != null) - message.protocol = String(object.protocol); - if (object.oldSourceIp != null) - message.oldSourceIp = String(object.oldSourceIp); - if (object.newSourceIp != null) - message.newSourceIp = String(object.newSourceIp); - if (object.oldDestinationIp != null) - message.oldDestinationIp = String(object.oldDestinationIp); - if (object.newDestinationIp != null) - message.newDestinationIp = String(object.newDestinationIp); - if (object.oldSourcePort != null) - message.oldSourcePort = object.oldSourcePort | 0; - if (object.newSourcePort != null) - message.newSourcePort = object.newSourcePort | 0; - if (object.oldDestinationPort != null) - message.oldDestinationPort = object.oldDestinationPort | 0; - if (object.newDestinationPort != null) - message.newDestinationPort = object.newDestinationPort | 0; - if (object.subnetUri != null) - message.subnetUri = String(object.subnetUri); - if (object.networkUri != null) - message.networkUri = String(object.networkUri); + var message = new $root.google.cloud.networkmanagement.v1.VpcConnectorInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.location != null) + message.location = String(object.location); return message; }; /** - * Creates a plain object from a ProxyConnectionInfo message. Also converts values to other types if specified. + * Creates a plain object from a VpcConnectorInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static - * @param {google.cloud.networkmanagement.v1.ProxyConnectionInfo} message ProxyConnectionInfo + * @param {google.cloud.networkmanagement.v1.VpcConnectorInfo} message VpcConnectorInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ProxyConnectionInfo.toObject = function toObject(message, options) { + VpcConnectorInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.protocol = ""; - object.oldSourceIp = ""; - object.newSourceIp = ""; - object.oldDestinationIp = ""; - object.newDestinationIp = ""; - object.oldSourcePort = 0; - object.newSourcePort = 0; - object.oldDestinationPort = 0; - object.newDestinationPort = 0; - object.subnetUri = ""; - object.networkUri = ""; + object.displayName = ""; + object.uri = ""; + object.location = ""; } - if (message.protocol != null && message.hasOwnProperty("protocol")) - object.protocol = message.protocol; - if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) - object.oldSourceIp = message.oldSourceIp; - if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) - object.newSourceIp = message.newSourceIp; - if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) - object.oldDestinationIp = message.oldDestinationIp; - if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) - object.newDestinationIp = message.newDestinationIp; - if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) - object.oldSourcePort = message.oldSourcePort; - if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) - object.newSourcePort = message.newSourcePort; - if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) - object.oldDestinationPort = message.oldDestinationPort; - if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) - object.newDestinationPort = message.newDestinationPort; - if (message.subnetUri != null && message.hasOwnProperty("subnetUri")) - object.subnetUri = message.subnetUri; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - object.networkUri = message.networkUri; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.location != null && message.hasOwnProperty("location")) + object.location = message.location; return object; }; /** - * Converts this ProxyConnectionInfo to JSON. + * Converts this VpcConnectorInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @instance * @returns {Object.} JSON object */ - ProxyConnectionInfo.prototype.toJSON = function toJSON() { + VpcConnectorInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ProxyConnectionInfo + * Gets the default type url for VpcConnectorInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @memberof google.cloud.networkmanagement.v1.VpcConnectorInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ProxyConnectionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + VpcConnectorInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ProxyConnectionInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.VpcConnectorInfo"; }; - return ProxyConnectionInfo; + return VpcConnectorInfo; })(); - v1.LoadBalancerBackendInfo = (function() { + v1.NatInfo = (function() { /** - * Properties of a LoadBalancerBackendInfo. + * Properties of a NatInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface ILoadBalancerBackendInfo - * @property {string|null} [name] LoadBalancerBackendInfo name - * @property {string|null} [instanceUri] LoadBalancerBackendInfo instanceUri - * @property {string|null} [backendServiceUri] LoadBalancerBackendInfo backendServiceUri - * @property {string|null} [instanceGroupUri] LoadBalancerBackendInfo instanceGroupUri - * @property {string|null} [networkEndpointGroupUri] LoadBalancerBackendInfo networkEndpointGroupUri - * @property {string|null} [backendBucketUri] LoadBalancerBackendInfo backendBucketUri - * @property {string|null} [pscServiceAttachmentUri] LoadBalancerBackendInfo pscServiceAttachmentUri - * @property {string|null} [pscGoogleApiTarget] LoadBalancerBackendInfo pscGoogleApiTarget - * @property {string|null} [healthCheckUri] LoadBalancerBackendInfo healthCheckUri - * @property {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState|null} [healthCheckFirewallsConfigState] LoadBalancerBackendInfo healthCheckFirewallsConfigState + * @interface INatInfo + * @property {google.cloud.networkmanagement.v1.NatInfo.Type|null} [type] NatInfo type + * @property {string|null} [protocol] NatInfo protocol + * @property {string|null} [networkUri] NatInfo networkUri + * @property {string|null} [oldSourceIp] NatInfo oldSourceIp + * @property {string|null} [newSourceIp] NatInfo newSourceIp + * @property {string|null} [oldDestinationIp] NatInfo oldDestinationIp + * @property {string|null} [newDestinationIp] NatInfo newDestinationIp + * @property {number|null} [oldSourcePort] NatInfo oldSourcePort + * @property {number|null} [newSourcePort] NatInfo newSourcePort + * @property {number|null} [oldDestinationPort] NatInfo oldDestinationPort + * @property {number|null} [newDestinationPort] NatInfo newDestinationPort + * @property {string|null} [routerUri] NatInfo routerUri + * @property {string|null} [natGatewayName] NatInfo natGatewayName */ /** - * Constructs a new LoadBalancerBackendInfo. + * Constructs a new NatInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a LoadBalancerBackendInfo. - * @implements ILoadBalancerBackendInfo + * @classdesc Represents a NatInfo. + * @implements INatInfo * @constructor - * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.INatInfo=} [properties] Properties to set */ - function LoadBalancerBackendInfo(properties) { + function NatInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14402,201 +14793,243 @@ } /** - * LoadBalancerBackendInfo name. - * @member {string} name - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo type. + * @member {google.cloud.networkmanagement.v1.NatInfo.Type} type + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.name = ""; + NatInfo.prototype.type = 0; /** - * LoadBalancerBackendInfo instanceUri. - * @member {string} instanceUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo protocol. + * @member {string} protocol + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.instanceUri = ""; + NatInfo.prototype.protocol = ""; /** - * LoadBalancerBackendInfo backendServiceUri. - * @member {string} backendServiceUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.backendServiceUri = ""; + NatInfo.prototype.networkUri = ""; /** - * LoadBalancerBackendInfo instanceGroupUri. - * @member {string} instanceGroupUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo oldSourceIp. + * @member {string} oldSourceIp + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.instanceGroupUri = ""; + NatInfo.prototype.oldSourceIp = ""; /** - * LoadBalancerBackendInfo networkEndpointGroupUri. - * @member {string} networkEndpointGroupUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo newSourceIp. + * @member {string} newSourceIp + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.networkEndpointGroupUri = ""; + NatInfo.prototype.newSourceIp = ""; /** - * LoadBalancerBackendInfo backendBucketUri. - * @member {string} backendBucketUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo oldDestinationIp. + * @member {string} oldDestinationIp + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.backendBucketUri = ""; + NatInfo.prototype.oldDestinationIp = ""; /** - * LoadBalancerBackendInfo pscServiceAttachmentUri. - * @member {string} pscServiceAttachmentUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo newDestinationIp. + * @member {string} newDestinationIp + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.pscServiceAttachmentUri = ""; + NatInfo.prototype.newDestinationIp = ""; /** - * LoadBalancerBackendInfo pscGoogleApiTarget. - * @member {string} pscGoogleApiTarget - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo oldSourcePort. + * @member {number} oldSourcePort + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.pscGoogleApiTarget = ""; + NatInfo.prototype.oldSourcePort = 0; /** - * LoadBalancerBackendInfo healthCheckUri. - * @member {string} healthCheckUri - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo newSourcePort. + * @member {number} newSourcePort + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.healthCheckUri = ""; + NatInfo.prototype.newSourcePort = 0; /** - * LoadBalancerBackendInfo healthCheckFirewallsConfigState. - * @member {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState} healthCheckFirewallsConfigState - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * NatInfo oldDestinationPort. + * @member {number} oldDestinationPort + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance */ - LoadBalancerBackendInfo.prototype.healthCheckFirewallsConfigState = 0; + NatInfo.prototype.oldDestinationPort = 0; /** - * Creates a new LoadBalancerBackendInfo instance using the specified properties. + * NatInfo newDestinationPort. + * @member {number} newDestinationPort + * @memberof google.cloud.networkmanagement.v1.NatInfo + * @instance + */ + NatInfo.prototype.newDestinationPort = 0; + + /** + * NatInfo routerUri. + * @member {string} routerUri + * @memberof google.cloud.networkmanagement.v1.NatInfo + * @instance + */ + NatInfo.prototype.routerUri = ""; + + /** + * NatInfo natGatewayName. + * @member {string} natGatewayName + * @memberof google.cloud.networkmanagement.v1.NatInfo + * @instance + */ + NatInfo.prototype.natGatewayName = ""; + + /** + * Creates a new NatInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static - * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo instance + * @param {google.cloud.networkmanagement.v1.INatInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo instance */ - LoadBalancerBackendInfo.create = function create(properties) { - return new LoadBalancerBackendInfo(properties); + NatInfo.create = function create(properties) { + return new NatInfo(properties); }; /** - * Encodes the specified LoadBalancerBackendInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.verify|verify} messages. + * Encodes the specified NatInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.NatInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static - * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo} message LoadBalancerBackendInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1.INatInfo} message NatInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - LoadBalancerBackendInfo.encode = function encode(message, writer) { + NatInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.instanceUri != null && Object.hasOwnProperty.call(message, "instanceUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.instanceUri); - if (message.backendServiceUri != null && Object.hasOwnProperty.call(message, "backendServiceUri")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.backendServiceUri); - if (message.instanceGroupUri != null && Object.hasOwnProperty.call(message, "instanceGroupUri")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.instanceGroupUri); - if (message.networkEndpointGroupUri != null && Object.hasOwnProperty.call(message, "networkEndpointGroupUri")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.networkEndpointGroupUri); - if (message.healthCheckUri != null && Object.hasOwnProperty.call(message, "healthCheckUri")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.healthCheckUri); - if (message.healthCheckFirewallsConfigState != null && Object.hasOwnProperty.call(message, "healthCheckFirewallsConfigState")) - writer.uint32(/* id 7, wireType 0 =*/56).int32(message.healthCheckFirewallsConfigState); - if (message.backendBucketUri != null && Object.hasOwnProperty.call(message, "backendBucketUri")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.backendBucketUri); - if (message.pscServiceAttachmentUri != null && Object.hasOwnProperty.call(message, "pscServiceAttachmentUri")) - writer.uint32(/* id 9, wireType 2 =*/74).string(message.pscServiceAttachmentUri); - if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.pscGoogleApiTarget); - return writer; - }; - - /** - * Encodes the specified LoadBalancerBackendInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo - * @static - * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo} message LoadBalancerBackendInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LoadBalancerBackendInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a LoadBalancerBackendInfo message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.type); + if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.protocol); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); + if (message.oldSourceIp != null && Object.hasOwnProperty.call(message, "oldSourceIp")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.oldSourceIp); + if (message.newSourceIp != null && Object.hasOwnProperty.call(message, "newSourceIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.newSourceIp); + if (message.oldDestinationIp != null && Object.hasOwnProperty.call(message, "oldDestinationIp")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.oldDestinationIp); + if (message.newDestinationIp != null && Object.hasOwnProperty.call(message, "newDestinationIp")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.newDestinationIp); + if (message.oldSourcePort != null && Object.hasOwnProperty.call(message, "oldSourcePort")) + writer.uint32(/* id 8, wireType 0 =*/64).int32(message.oldSourcePort); + if (message.newSourcePort != null && Object.hasOwnProperty.call(message, "newSourcePort")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.newSourcePort); + if (message.oldDestinationPort != null && Object.hasOwnProperty.call(message, "oldDestinationPort")) + writer.uint32(/* id 10, wireType 0 =*/80).int32(message.oldDestinationPort); + if (message.newDestinationPort != null && Object.hasOwnProperty.call(message, "newDestinationPort")) + writer.uint32(/* id 11, wireType 0 =*/88).int32(message.newDestinationPort); + if (message.routerUri != null && Object.hasOwnProperty.call(message, "routerUri")) + writer.uint32(/* id 12, wireType 2 =*/98).string(message.routerUri); + if (message.natGatewayName != null && Object.hasOwnProperty.call(message, "natGatewayName")) + writer.uint32(/* id 13, wireType 2 =*/106).string(message.natGatewayName); + return writer; + }; + + /** + * Encodes the specified NatInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.NatInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1.NatInfo + * @static + * @param {google.cloud.networkmanagement.v1.INatInfo} message NatInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + NatInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a NatInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1.NatInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo + * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - LoadBalancerBackendInfo.decode = function decode(reader, length) { + NatInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.NatInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.type = reader.int32(); break; } case 2: { - message.instanceUri = reader.string(); + message.protocol = reader.string(); break; } case 3: { - message.backendServiceUri = reader.string(); + message.networkUri = reader.string(); break; } case 4: { - message.instanceGroupUri = reader.string(); + message.oldSourceIp = reader.string(); break; } case 5: { - message.networkEndpointGroupUri = reader.string(); + message.newSourceIp = reader.string(); + break; + } + case 6: { + message.oldDestinationIp = reader.string(); + break; + } + case 7: { + message.newDestinationIp = reader.string(); break; } case 8: { - message.backendBucketUri = reader.string(); + message.oldSourcePort = reader.int32(); break; } case 9: { - message.pscServiceAttachmentUri = reader.string(); + message.newSourcePort = reader.int32(); break; } case 10: { - message.pscGoogleApiTarget = reader.string(); + message.oldDestinationPort = reader.int32(); break; } - case 6: { - message.healthCheckUri = reader.string(); + case 11: { + message.newDestinationPort = reader.int32(); break; } - case 7: { - message.healthCheckFirewallsConfigState = reader.int32(); + case 12: { + message.routerUri = reader.string(); + break; + } + case 13: { + message.natGatewayName = reader.string(); break; } default: @@ -14608,63 +15041,36 @@ }; /** - * Decodes a LoadBalancerBackendInfo message from the specified reader or buffer, length delimited. + * Decodes a NatInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo + * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - LoadBalancerBackendInfo.decodeDelimited = function decodeDelimited(reader) { + NatInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a LoadBalancerBackendInfo message. + * Verifies a NatInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - LoadBalancerBackendInfo.verify = function verify(message) { + NatInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.instanceUri != null && message.hasOwnProperty("instanceUri")) - if (!$util.isString(message.instanceUri)) - return "instanceUri: string expected"; - if (message.backendServiceUri != null && message.hasOwnProperty("backendServiceUri")) - if (!$util.isString(message.backendServiceUri)) - return "backendServiceUri: string expected"; - if (message.instanceGroupUri != null && message.hasOwnProperty("instanceGroupUri")) - if (!$util.isString(message.instanceGroupUri)) - return "instanceGroupUri: string expected"; - if (message.networkEndpointGroupUri != null && message.hasOwnProperty("networkEndpointGroupUri")) - if (!$util.isString(message.networkEndpointGroupUri)) - return "networkEndpointGroupUri: string expected"; - if (message.backendBucketUri != null && message.hasOwnProperty("backendBucketUri")) - if (!$util.isString(message.backendBucketUri)) - return "backendBucketUri: string expected"; - if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) - if (!$util.isString(message.pscServiceAttachmentUri)) - return "pscServiceAttachmentUri: string expected"; - if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) - if (!$util.isString(message.pscGoogleApiTarget)) - return "pscGoogleApiTarget: string expected"; - if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) - if (!$util.isString(message.healthCheckUri)) - return "healthCheckUri: string expected"; - if (message.healthCheckFirewallsConfigState != null && message.hasOwnProperty("healthCheckFirewallsConfigState")) - switch (message.healthCheckFirewallsConfigState) { + if (message.type != null && message.hasOwnProperty("type")) + switch (message.type) { default: - return "healthCheckFirewallsConfigState: enum value expected"; + return "type: enum value expected"; case 0: case 1: case 2: @@ -14672,217 +15078,246 @@ case 4: break; } + if (message.protocol != null && message.hasOwnProperty("protocol")) + if (!$util.isString(message.protocol)) + return "protocol: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) + if (!$util.isString(message.oldSourceIp)) + return "oldSourceIp: string expected"; + if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) + if (!$util.isString(message.newSourceIp)) + return "newSourceIp: string expected"; + if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) + if (!$util.isString(message.oldDestinationIp)) + return "oldDestinationIp: string expected"; + if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) + if (!$util.isString(message.newDestinationIp)) + return "newDestinationIp: string expected"; + if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) + if (!$util.isInteger(message.oldSourcePort)) + return "oldSourcePort: integer expected"; + if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) + if (!$util.isInteger(message.newSourcePort)) + return "newSourcePort: integer expected"; + if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) + if (!$util.isInteger(message.oldDestinationPort)) + return "oldDestinationPort: integer expected"; + if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) + if (!$util.isInteger(message.newDestinationPort)) + return "newDestinationPort: integer expected"; + if (message.routerUri != null && message.hasOwnProperty("routerUri")) + if (!$util.isString(message.routerUri)) + return "routerUri: string expected"; + if (message.natGatewayName != null && message.hasOwnProperty("natGatewayName")) + if (!$util.isString(message.natGatewayName)) + return "natGatewayName: string expected"; return null; }; /** - * Creates a LoadBalancerBackendInfo message from a plain object. Also converts values to their respective internal types. + * Creates a NatInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo + * @returns {google.cloud.networkmanagement.v1.NatInfo} NatInfo */ - LoadBalancerBackendInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo) + NatInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.NatInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo(); - if (object.name != null) - message.name = String(object.name); - if (object.instanceUri != null) - message.instanceUri = String(object.instanceUri); - if (object.backendServiceUri != null) - message.backendServiceUri = String(object.backendServiceUri); - if (object.instanceGroupUri != null) - message.instanceGroupUri = String(object.instanceGroupUri); - if (object.networkEndpointGroupUri != null) - message.networkEndpointGroupUri = String(object.networkEndpointGroupUri); - if (object.backendBucketUri != null) - message.backendBucketUri = String(object.backendBucketUri); - if (object.pscServiceAttachmentUri != null) - message.pscServiceAttachmentUri = String(object.pscServiceAttachmentUri); - if (object.pscGoogleApiTarget != null) - message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); - if (object.healthCheckUri != null) - message.healthCheckUri = String(object.healthCheckUri); - switch (object.healthCheckFirewallsConfigState) { + var message = new $root.google.cloud.networkmanagement.v1.NatInfo(); + switch (object.type) { default: - if (typeof object.healthCheckFirewallsConfigState === "number") { - message.healthCheckFirewallsConfigState = object.healthCheckFirewallsConfigState; + if (typeof object.type === "number") { + message.type = object.type; break; } break; - case "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED": + case "TYPE_UNSPECIFIED": case 0: - message.healthCheckFirewallsConfigState = 0; + message.type = 0; break; - case "FIREWALLS_CONFIGURED": + case "INTERNAL_TO_EXTERNAL": case 1: - message.healthCheckFirewallsConfigState = 1; + message.type = 1; break; - case "FIREWALLS_PARTIALLY_CONFIGURED": + case "EXTERNAL_TO_INTERNAL": case 2: - message.healthCheckFirewallsConfigState = 2; + message.type = 2; break; - case "FIREWALLS_NOT_CONFIGURED": + case "CLOUD_NAT": case 3: - message.healthCheckFirewallsConfigState = 3; + message.type = 3; break; - case "FIREWALLS_UNSUPPORTED": + case "PRIVATE_SERVICE_CONNECT": case 4: - message.healthCheckFirewallsConfigState = 4; + message.type = 4; break; } + if (object.protocol != null) + message.protocol = String(object.protocol); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.oldSourceIp != null) + message.oldSourceIp = String(object.oldSourceIp); + if (object.newSourceIp != null) + message.newSourceIp = String(object.newSourceIp); + if (object.oldDestinationIp != null) + message.oldDestinationIp = String(object.oldDestinationIp); + if (object.newDestinationIp != null) + message.newDestinationIp = String(object.newDestinationIp); + if (object.oldSourcePort != null) + message.oldSourcePort = object.oldSourcePort | 0; + if (object.newSourcePort != null) + message.newSourcePort = object.newSourcePort | 0; + if (object.oldDestinationPort != null) + message.oldDestinationPort = object.oldDestinationPort | 0; + if (object.newDestinationPort != null) + message.newDestinationPort = object.newDestinationPort | 0; + if (object.routerUri != null) + message.routerUri = String(object.routerUri); + if (object.natGatewayName != null) + message.natGatewayName = String(object.natGatewayName); return message; }; /** - * Creates a plain object from a LoadBalancerBackendInfo message. Also converts values to other types if specified. + * Creates a plain object from a NatInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static - * @param {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} message LoadBalancerBackendInfo + * @param {google.cloud.networkmanagement.v1.NatInfo} message NatInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - LoadBalancerBackendInfo.toObject = function toObject(message, options) { + NatInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.name = ""; - object.instanceUri = ""; - object.backendServiceUri = ""; - object.instanceGroupUri = ""; - object.networkEndpointGroupUri = ""; - object.healthCheckUri = ""; - object.healthCheckFirewallsConfigState = options.enums === String ? "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED" : 0; - object.backendBucketUri = ""; - object.pscServiceAttachmentUri = ""; - object.pscGoogleApiTarget = ""; + object.type = options.enums === String ? "TYPE_UNSPECIFIED" : 0; + object.protocol = ""; + object.networkUri = ""; + object.oldSourceIp = ""; + object.newSourceIp = ""; + object.oldDestinationIp = ""; + object.newDestinationIp = ""; + object.oldSourcePort = 0; + object.newSourcePort = 0; + object.oldDestinationPort = 0; + object.newDestinationPort = 0; + object.routerUri = ""; + object.natGatewayName = ""; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.instanceUri != null && message.hasOwnProperty("instanceUri")) - object.instanceUri = message.instanceUri; - if (message.backendServiceUri != null && message.hasOwnProperty("backendServiceUri")) - object.backendServiceUri = message.backendServiceUri; - if (message.instanceGroupUri != null && message.hasOwnProperty("instanceGroupUri")) - object.instanceGroupUri = message.instanceGroupUri; - if (message.networkEndpointGroupUri != null && message.hasOwnProperty("networkEndpointGroupUri")) - object.networkEndpointGroupUri = message.networkEndpointGroupUri; - if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) - object.healthCheckUri = message.healthCheckUri; - if (message.healthCheckFirewallsConfigState != null && message.hasOwnProperty("healthCheckFirewallsConfigState")) - object.healthCheckFirewallsConfigState = options.enums === String ? $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState[message.healthCheckFirewallsConfigState] === undefined ? message.healthCheckFirewallsConfigState : $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState[message.healthCheckFirewallsConfigState] : message.healthCheckFirewallsConfigState; - if (message.backendBucketUri != null && message.hasOwnProperty("backendBucketUri")) - object.backendBucketUri = message.backendBucketUri; - if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) - object.pscServiceAttachmentUri = message.pscServiceAttachmentUri; - if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) - object.pscGoogleApiTarget = message.pscGoogleApiTarget; + if (message.type != null && message.hasOwnProperty("type")) + object.type = options.enums === String ? $root.google.cloud.networkmanagement.v1.NatInfo.Type[message.type] === undefined ? message.type : $root.google.cloud.networkmanagement.v1.NatInfo.Type[message.type] : message.type; + if (message.protocol != null && message.hasOwnProperty("protocol")) + object.protocol = message.protocol; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) + object.oldSourceIp = message.oldSourceIp; + if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) + object.newSourceIp = message.newSourceIp; + if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) + object.oldDestinationIp = message.oldDestinationIp; + if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) + object.newDestinationIp = message.newDestinationIp; + if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) + object.oldSourcePort = message.oldSourcePort; + if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) + object.newSourcePort = message.newSourcePort; + if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) + object.oldDestinationPort = message.oldDestinationPort; + if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) + object.newDestinationPort = message.newDestinationPort; + if (message.routerUri != null && message.hasOwnProperty("routerUri")) + object.routerUri = message.routerUri; + if (message.natGatewayName != null && message.hasOwnProperty("natGatewayName")) + object.natGatewayName = message.natGatewayName; return object; }; /** - * Converts this LoadBalancerBackendInfo to JSON. + * Converts this NatInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @instance * @returns {Object.} JSON object */ - LoadBalancerBackendInfo.prototype.toJSON = function toJSON() { + NatInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for LoadBalancerBackendInfo + * Gets the default type url for NatInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1.NatInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - LoadBalancerBackendInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + NatInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.LoadBalancerBackendInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.NatInfo"; }; /** - * HealthCheckFirewallsConfigState enum. - * @name google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState + * Type enum. + * @name google.cloud.networkmanagement.v1.NatInfo.Type * @enum {number} - * @property {number} HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED=0 HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED value - * @property {number} FIREWALLS_CONFIGURED=1 FIREWALLS_CONFIGURED value - * @property {number} FIREWALLS_PARTIALLY_CONFIGURED=2 FIREWALLS_PARTIALLY_CONFIGURED value - * @property {number} FIREWALLS_NOT_CONFIGURED=3 FIREWALLS_NOT_CONFIGURED value - * @property {number} FIREWALLS_UNSUPPORTED=4 FIREWALLS_UNSUPPORTED value + * @property {number} TYPE_UNSPECIFIED=0 TYPE_UNSPECIFIED value + * @property {number} INTERNAL_TO_EXTERNAL=1 INTERNAL_TO_EXTERNAL value + * @property {number} EXTERNAL_TO_INTERNAL=2 EXTERNAL_TO_INTERNAL value + * @property {number} CLOUD_NAT=3 CLOUD_NAT value + * @property {number} PRIVATE_SERVICE_CONNECT=4 PRIVATE_SERVICE_CONNECT value */ - LoadBalancerBackendInfo.HealthCheckFirewallsConfigState = (function() { + NatInfo.Type = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED"] = 0; - values[valuesById[1] = "FIREWALLS_CONFIGURED"] = 1; - values[valuesById[2] = "FIREWALLS_PARTIALLY_CONFIGURED"] = 2; - values[valuesById[3] = "FIREWALLS_NOT_CONFIGURED"] = 3; - values[valuesById[4] = "FIREWALLS_UNSUPPORTED"] = 4; + values[valuesById[0] = "TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "INTERNAL_TO_EXTERNAL"] = 1; + values[valuesById[2] = "EXTERNAL_TO_INTERNAL"] = 2; + values[valuesById[3] = "CLOUD_NAT"] = 3; + values[valuesById[4] = "PRIVATE_SERVICE_CONNECT"] = 4; return values; })(); - return LoadBalancerBackendInfo; - })(); - - /** - * LoadBalancerType enum. - * @name google.cloud.networkmanagement.v1.LoadBalancerType - * @enum {number} - * @property {number} LOAD_BALANCER_TYPE_UNSPECIFIED=0 LOAD_BALANCER_TYPE_UNSPECIFIED value - * @property {number} HTTPS_ADVANCED_LOAD_BALANCER=1 HTTPS_ADVANCED_LOAD_BALANCER value - * @property {number} HTTPS_LOAD_BALANCER=2 HTTPS_LOAD_BALANCER value - * @property {number} REGIONAL_HTTPS_LOAD_BALANCER=3 REGIONAL_HTTPS_LOAD_BALANCER value - * @property {number} INTERNAL_HTTPS_LOAD_BALANCER=4 INTERNAL_HTTPS_LOAD_BALANCER value - * @property {number} SSL_PROXY_LOAD_BALANCER=5 SSL_PROXY_LOAD_BALANCER value - * @property {number} TCP_PROXY_LOAD_BALANCER=6 TCP_PROXY_LOAD_BALANCER value - * @property {number} INTERNAL_TCP_PROXY_LOAD_BALANCER=7 INTERNAL_TCP_PROXY_LOAD_BALANCER value - * @property {number} NETWORK_LOAD_BALANCER=8 NETWORK_LOAD_BALANCER value - * @property {number} LEGACY_NETWORK_LOAD_BALANCER=9 LEGACY_NETWORK_LOAD_BALANCER value - * @property {number} TCP_UDP_INTERNAL_LOAD_BALANCER=10 TCP_UDP_INTERNAL_LOAD_BALANCER value - */ - v1.LoadBalancerType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "LOAD_BALANCER_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "HTTPS_ADVANCED_LOAD_BALANCER"] = 1; - values[valuesById[2] = "HTTPS_LOAD_BALANCER"] = 2; - values[valuesById[3] = "REGIONAL_HTTPS_LOAD_BALANCER"] = 3; - values[valuesById[4] = "INTERNAL_HTTPS_LOAD_BALANCER"] = 4; - values[valuesById[5] = "SSL_PROXY_LOAD_BALANCER"] = 5; - values[valuesById[6] = "TCP_PROXY_LOAD_BALANCER"] = 6; - values[valuesById[7] = "INTERNAL_TCP_PROXY_LOAD_BALANCER"] = 7; - values[valuesById[8] = "NETWORK_LOAD_BALANCER"] = 8; - values[valuesById[9] = "LEGACY_NETWORK_LOAD_BALANCER"] = 9; - values[valuesById[10] = "TCP_UDP_INTERNAL_LOAD_BALANCER"] = 10; - return values; + return NatInfo; })(); - v1.StorageBucketInfo = (function() { + v1.ProxyConnectionInfo = (function() { /** - * Properties of a StorageBucketInfo. + * Properties of a ProxyConnectionInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface IStorageBucketInfo - * @property {string|null} [bucket] StorageBucketInfo bucket + * @interface IProxyConnectionInfo + * @property {string|null} [protocol] ProxyConnectionInfo protocol + * @property {string|null} [oldSourceIp] ProxyConnectionInfo oldSourceIp + * @property {string|null} [newSourceIp] ProxyConnectionInfo newSourceIp + * @property {string|null} [oldDestinationIp] ProxyConnectionInfo oldDestinationIp + * @property {string|null} [newDestinationIp] ProxyConnectionInfo newDestinationIp + * @property {number|null} [oldSourcePort] ProxyConnectionInfo oldSourcePort + * @property {number|null} [newSourcePort] ProxyConnectionInfo newSourcePort + * @property {number|null} [oldDestinationPort] ProxyConnectionInfo oldDestinationPort + * @property {number|null} [newDestinationPort] ProxyConnectionInfo newDestinationPort + * @property {string|null} [subnetUri] ProxyConnectionInfo subnetUri + * @property {string|null} [networkUri] ProxyConnectionInfo networkUri */ /** - * Constructs a new StorageBucketInfo. + * Constructs a new ProxyConnectionInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a StorageBucketInfo. - * @implements IStorageBucketInfo + * @classdesc Represents a ProxyConnectionInfo. + * @implements IProxyConnectionInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo=} [properties] Properties to set */ - function StorageBucketInfo(properties) { + function ProxyConnectionInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14890,77 +15325,217 @@ } /** - * StorageBucketInfo bucket. - * @member {string} bucket - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * ProxyConnectionInfo protocol. + * @member {string} protocol + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @instance */ - StorageBucketInfo.prototype.bucket = ""; + ProxyConnectionInfo.prototype.protocol = ""; /** - * Creates a new StorageBucketInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo - * @static - * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo instance + * ProxyConnectionInfo oldSourceIp. + * @member {string} oldSourceIp + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance */ - StorageBucketInfo.create = function create(properties) { - return new StorageBucketInfo(properties); - }; + ProxyConnectionInfo.prototype.oldSourceIp = ""; /** - * Encodes the specified StorageBucketInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.StorageBucketInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo - * @static - * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo} message StorageBucketInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * ProxyConnectionInfo newSourceIp. + * @member {string} newSourceIp + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance */ - StorageBucketInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.bucket != null && Object.hasOwnProperty.call(message, "bucket")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.bucket); - return writer; - }; + ProxyConnectionInfo.prototype.newSourceIp = ""; /** - * Encodes the specified StorageBucketInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.StorageBucketInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo - * @static - * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo} message StorageBucketInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * ProxyConnectionInfo oldDestinationIp. + * @member {string} oldDestinationIp + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance */ - StorageBucketInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + ProxyConnectionInfo.prototype.oldDestinationIp = ""; /** - * Decodes a StorageBucketInfo message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * ProxyConnectionInfo newDestinationIp. + * @member {string} newDestinationIp + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance */ - StorageBucketInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.StorageBucketInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.bucket = reader.string(); - break; - } + ProxyConnectionInfo.prototype.newDestinationIp = ""; + + /** + * ProxyConnectionInfo oldSourcePort. + * @member {number} oldSourcePort + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.oldSourcePort = 0; + + /** + * ProxyConnectionInfo newSourcePort. + * @member {number} newSourcePort + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.newSourcePort = 0; + + /** + * ProxyConnectionInfo oldDestinationPort. + * @member {number} oldDestinationPort + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.oldDestinationPort = 0; + + /** + * ProxyConnectionInfo newDestinationPort. + * @member {number} newDestinationPort + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.newDestinationPort = 0; + + /** + * ProxyConnectionInfo subnetUri. + * @member {string} subnetUri + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.subnetUri = ""; + + /** + * ProxyConnectionInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @instance + */ + ProxyConnectionInfo.prototype.networkUri = ""; + + /** + * Creates a new ProxyConnectionInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @static + * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo instance + */ + ProxyConnectionInfo.create = function create(properties) { + return new ProxyConnectionInfo(properties); + }; + + /** + * Encodes the specified ProxyConnectionInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.ProxyConnectionInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @static + * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo} message ProxyConnectionInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ProxyConnectionInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.protocol); + if (message.oldSourceIp != null && Object.hasOwnProperty.call(message, "oldSourceIp")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.oldSourceIp); + if (message.newSourceIp != null && Object.hasOwnProperty.call(message, "newSourceIp")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.newSourceIp); + if (message.oldDestinationIp != null && Object.hasOwnProperty.call(message, "oldDestinationIp")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.oldDestinationIp); + if (message.newDestinationIp != null && Object.hasOwnProperty.call(message, "newDestinationIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.newDestinationIp); + if (message.oldSourcePort != null && Object.hasOwnProperty.call(message, "oldSourcePort")) + writer.uint32(/* id 6, wireType 0 =*/48).int32(message.oldSourcePort); + if (message.newSourcePort != null && Object.hasOwnProperty.call(message, "newSourcePort")) + writer.uint32(/* id 7, wireType 0 =*/56).int32(message.newSourcePort); + if (message.oldDestinationPort != null && Object.hasOwnProperty.call(message, "oldDestinationPort")) + writer.uint32(/* id 8, wireType 0 =*/64).int32(message.oldDestinationPort); + if (message.newDestinationPort != null && Object.hasOwnProperty.call(message, "newDestinationPort")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.newDestinationPort); + if (message.subnetUri != null && Object.hasOwnProperty.call(message, "subnetUri")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.subnetUri); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.networkUri); + return writer; + }; + + /** + * Encodes the specified ProxyConnectionInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ProxyConnectionInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @static + * @param {google.cloud.networkmanagement.v1.IProxyConnectionInfo} message ProxyConnectionInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ProxyConnectionInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ProxyConnectionInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ProxyConnectionInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.protocol = reader.string(); + break; + } + case 2: { + message.oldSourceIp = reader.string(); + break; + } + case 3: { + message.newSourceIp = reader.string(); + break; + } + case 4: { + message.oldDestinationIp = reader.string(); + break; + } + case 5: { + message.newDestinationIp = reader.string(); + break; + } + case 6: { + message.oldSourcePort = reader.int32(); + break; + } + case 7: { + message.newSourcePort = reader.int32(); + break; + } + case 8: { + message.oldDestinationPort = reader.int32(); + break; + } + case 9: { + message.newDestinationPort = reader.int32(); + break; + } + case 10: { + message.subnetUri = reader.string(); + break; + } + case 11: { + message.networkUri = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -14970,655 +15545,700 @@ }; /** - * Decodes a StorageBucketInfo message from the specified reader or buffer, length delimited. + * Decodes a ProxyConnectionInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo + * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - StorageBucketInfo.decodeDelimited = function decodeDelimited(reader) { + ProxyConnectionInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a StorageBucketInfo message. + * Verifies a ProxyConnectionInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - StorageBucketInfo.verify = function verify(message) { + ProxyConnectionInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.bucket != null && message.hasOwnProperty("bucket")) - if (!$util.isString(message.bucket)) - return "bucket: string expected"; + if (message.protocol != null && message.hasOwnProperty("protocol")) + if (!$util.isString(message.protocol)) + return "protocol: string expected"; + if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) + if (!$util.isString(message.oldSourceIp)) + return "oldSourceIp: string expected"; + if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) + if (!$util.isString(message.newSourceIp)) + return "newSourceIp: string expected"; + if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) + if (!$util.isString(message.oldDestinationIp)) + return "oldDestinationIp: string expected"; + if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) + if (!$util.isString(message.newDestinationIp)) + return "newDestinationIp: string expected"; + if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) + if (!$util.isInteger(message.oldSourcePort)) + return "oldSourcePort: integer expected"; + if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) + if (!$util.isInteger(message.newSourcePort)) + return "newSourcePort: integer expected"; + if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) + if (!$util.isInteger(message.oldDestinationPort)) + return "oldDestinationPort: integer expected"; + if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) + if (!$util.isInteger(message.newDestinationPort)) + return "newDestinationPort: integer expected"; + if (message.subnetUri != null && message.hasOwnProperty("subnetUri")) + if (!$util.isString(message.subnetUri)) + return "subnetUri: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; return null; }; /** - * Creates a StorageBucketInfo message from a plain object. Also converts values to their respective internal types. + * Creates a ProxyConnectionInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo + * @returns {google.cloud.networkmanagement.v1.ProxyConnectionInfo} ProxyConnectionInfo */ - StorageBucketInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.StorageBucketInfo) + ProxyConnectionInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.StorageBucketInfo(); - if (object.bucket != null) - message.bucket = String(object.bucket); - return message; - }; - - /** - * Creates a plain object from a StorageBucketInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo - * @static - * @param {google.cloud.networkmanagement.v1.StorageBucketInfo} message StorageBucketInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - StorageBucketInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.bucket = ""; - if (message.bucket != null && message.hasOwnProperty("bucket")) - object.bucket = message.bucket; + var message = new $root.google.cloud.networkmanagement.v1.ProxyConnectionInfo(); + if (object.protocol != null) + message.protocol = String(object.protocol); + if (object.oldSourceIp != null) + message.oldSourceIp = String(object.oldSourceIp); + if (object.newSourceIp != null) + message.newSourceIp = String(object.newSourceIp); + if (object.oldDestinationIp != null) + message.oldDestinationIp = String(object.oldDestinationIp); + if (object.newDestinationIp != null) + message.newDestinationIp = String(object.newDestinationIp); + if (object.oldSourcePort != null) + message.oldSourcePort = object.oldSourcePort | 0; + if (object.newSourcePort != null) + message.newSourcePort = object.newSourcePort | 0; + if (object.oldDestinationPort != null) + message.oldDestinationPort = object.oldDestinationPort | 0; + if (object.newDestinationPort != null) + message.newDestinationPort = object.newDestinationPort | 0; + if (object.subnetUri != null) + message.subnetUri = String(object.subnetUri); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + return message; + }; + + /** + * Creates a plain object from a ProxyConnectionInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo + * @static + * @param {google.cloud.networkmanagement.v1.ProxyConnectionInfo} message ProxyConnectionInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ProxyConnectionInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.protocol = ""; + object.oldSourceIp = ""; + object.newSourceIp = ""; + object.oldDestinationIp = ""; + object.newDestinationIp = ""; + object.oldSourcePort = 0; + object.newSourcePort = 0; + object.oldDestinationPort = 0; + object.newDestinationPort = 0; + object.subnetUri = ""; + object.networkUri = ""; + } + if (message.protocol != null && message.hasOwnProperty("protocol")) + object.protocol = message.protocol; + if (message.oldSourceIp != null && message.hasOwnProperty("oldSourceIp")) + object.oldSourceIp = message.oldSourceIp; + if (message.newSourceIp != null && message.hasOwnProperty("newSourceIp")) + object.newSourceIp = message.newSourceIp; + if (message.oldDestinationIp != null && message.hasOwnProperty("oldDestinationIp")) + object.oldDestinationIp = message.oldDestinationIp; + if (message.newDestinationIp != null && message.hasOwnProperty("newDestinationIp")) + object.newDestinationIp = message.newDestinationIp; + if (message.oldSourcePort != null && message.hasOwnProperty("oldSourcePort")) + object.oldSourcePort = message.oldSourcePort; + if (message.newSourcePort != null && message.hasOwnProperty("newSourcePort")) + object.newSourcePort = message.newSourcePort; + if (message.oldDestinationPort != null && message.hasOwnProperty("oldDestinationPort")) + object.oldDestinationPort = message.oldDestinationPort; + if (message.newDestinationPort != null && message.hasOwnProperty("newDestinationPort")) + object.newDestinationPort = message.newDestinationPort; + if (message.subnetUri != null && message.hasOwnProperty("subnetUri")) + object.subnetUri = message.subnetUri; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; return object; }; /** - * Converts this StorageBucketInfo to JSON. + * Converts this ProxyConnectionInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @instance * @returns {Object.} JSON object */ - StorageBucketInfo.prototype.toJSON = function toJSON() { + ProxyConnectionInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for StorageBucketInfo + * Gets the default type url for ProxyConnectionInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo + * @memberof google.cloud.networkmanagement.v1.ProxyConnectionInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - StorageBucketInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ProxyConnectionInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.StorageBucketInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ProxyConnectionInfo"; }; - return StorageBucketInfo; + return ProxyConnectionInfo; })(); - v1.ReachabilityService = (function() { + v1.LoadBalancerBackendInfo = (function() { /** - * Constructs a new ReachabilityService service. + * Properties of a LoadBalancerBackendInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a ReachabilityService - * @extends $protobuf.rpc.Service - * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @interface ILoadBalancerBackendInfo + * @property {string|null} [name] LoadBalancerBackendInfo name + * @property {string|null} [instanceUri] LoadBalancerBackendInfo instanceUri + * @property {string|null} [backendServiceUri] LoadBalancerBackendInfo backendServiceUri + * @property {string|null} [instanceGroupUri] LoadBalancerBackendInfo instanceGroupUri + * @property {string|null} [networkEndpointGroupUri] LoadBalancerBackendInfo networkEndpointGroupUri + * @property {string|null} [backendBucketUri] LoadBalancerBackendInfo backendBucketUri + * @property {string|null} [pscServiceAttachmentUri] LoadBalancerBackendInfo pscServiceAttachmentUri + * @property {string|null} [pscGoogleApiTarget] LoadBalancerBackendInfo pscGoogleApiTarget + * @property {string|null} [healthCheckUri] LoadBalancerBackendInfo healthCheckUri + * @property {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState|null} [healthCheckFirewallsConfigState] LoadBalancerBackendInfo healthCheckFirewallsConfigState */ - function ReachabilityService(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); - } - - (ReachabilityService.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = ReachabilityService; /** - * Creates new ReachabilityService service using the specified rpc implementation. - * @function create - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {ReachabilityService} RPC service. Useful where requests and/or responses are streamed. + * Constructs a new LoadBalancerBackendInfo. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents a LoadBalancerBackendInfo. + * @implements ILoadBalancerBackendInfo + * @constructor + * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo=} [properties] Properties to set */ - ReachabilityService.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); - }; + function LoadBalancerBackendInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|listConnectivityTests}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef ListConnectivityTestsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} [response] ListConnectivityTestsResponse + * LoadBalancerBackendInfo name. + * @member {string} name + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @instance */ + LoadBalancerBackendInfo.prototype.name = ""; /** - * Calls ListConnectivityTests. - * @function listConnectivityTests - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo instanceUri. + * @member {string} instanceUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} request ListConnectivityTestsRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.ListConnectivityTestsCallback} callback Node-style callback called with the error, if any, and ListConnectivityTestsResponse - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(ReachabilityService.prototype.listConnectivityTests = function listConnectivityTests(request, callback) { - return this.rpcCall(listConnectivityTests, $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest, $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse, request, callback); - }, "name", { value: "ListConnectivityTests" }); + LoadBalancerBackendInfo.prototype.instanceUri = ""; /** - * Calls ListConnectivityTests. - * @function listConnectivityTests - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo backendServiceUri. + * @member {string} backendServiceUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} request ListConnectivityTestsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + LoadBalancerBackendInfo.prototype.backendServiceUri = ""; /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|getConnectivityTest}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef GetConnectivityTestCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.networkmanagement.v1.ConnectivityTest} [response] ConnectivityTest + * LoadBalancerBackendInfo instanceGroupUri. + * @member {string} instanceGroupUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @instance */ + LoadBalancerBackendInfo.prototype.instanceGroupUri = ""; /** - * Calls GetConnectivityTest. - * @function getConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo networkEndpointGroupUri. + * @member {string} networkEndpointGroupUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} request GetConnectivityTestRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.GetConnectivityTestCallback} callback Node-style callback called with the error, if any, and ConnectivityTest - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(ReachabilityService.prototype.getConnectivityTest = function getConnectivityTest(request, callback) { - return this.rpcCall(getConnectivityTest, $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest, $root.google.cloud.networkmanagement.v1.ConnectivityTest, request, callback); - }, "name", { value: "GetConnectivityTest" }); + LoadBalancerBackendInfo.prototype.networkEndpointGroupUri = ""; /** - * Calls GetConnectivityTest. - * @function getConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo backendBucketUri. + * @member {string} backendBucketUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} request GetConnectivityTestRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + LoadBalancerBackendInfo.prototype.backendBucketUri = ""; /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|createConnectivityTest}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef CreateConnectivityTestCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.longrunning.Operation} [response] Operation + * LoadBalancerBackendInfo pscServiceAttachmentUri. + * @member {string} pscServiceAttachmentUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @instance */ + LoadBalancerBackendInfo.prototype.pscServiceAttachmentUri = ""; /** - * Calls CreateConnectivityTest. - * @function createConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo pscGoogleApiTarget. + * @member {string} pscGoogleApiTarget + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} request CreateConnectivityTestRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.CreateConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(ReachabilityService.prototype.createConnectivityTest = function createConnectivityTest(request, callback) { - return this.rpcCall(createConnectivityTest, $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); - }, "name", { value: "CreateConnectivityTest" }); + LoadBalancerBackendInfo.prototype.pscGoogleApiTarget = ""; /** - * Calls CreateConnectivityTest. - * @function createConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * LoadBalancerBackendInfo healthCheckUri. + * @member {string} healthCheckUri + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} request CreateConnectivityTestRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + LoadBalancerBackendInfo.prototype.healthCheckUri = ""; /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|updateConnectivityTest}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef UpdateConnectivityTestCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.longrunning.Operation} [response] Operation + * LoadBalancerBackendInfo healthCheckFirewallsConfigState. + * @member {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState} healthCheckFirewallsConfigState + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @instance */ + LoadBalancerBackendInfo.prototype.healthCheckFirewallsConfigState = 0; /** - * Calls UpdateConnectivityTest. - * @function updateConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} request UpdateConnectivityTestRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.UpdateConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(ReachabilityService.prototype.updateConnectivityTest = function updateConnectivityTest(request, callback) { - return this.rpcCall(updateConnectivityTest, $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); - }, "name", { value: "UpdateConnectivityTest" }); - - /** - * Calls UpdateConnectivityTest. - * @function updateConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} request UpdateConnectivityTestRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|rerunConnectivityTest}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef RerunConnectivityTestCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.longrunning.Operation} [response] Operation - */ - - /** - * Calls RerunConnectivityTest. - * @function rerunConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} request RerunConnectivityTestRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.RerunConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(ReachabilityService.prototype.rerunConnectivityTest = function rerunConnectivityTest(request, callback) { - return this.rpcCall(rerunConnectivityTest, $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); - }, "name", { value: "RerunConnectivityTest" }); - - /** - * Calls RerunConnectivityTest. - * @function rerunConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} request RerunConnectivityTestRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|deleteConnectivityTest}. - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @typedef DeleteConnectivityTestCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.longrunning.Operation} [response] Operation - */ - - /** - * Calls DeleteConnectivityTest. - * @function deleteConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} request DeleteConnectivityTestRequest message or plain object - * @param {google.cloud.networkmanagement.v1.ReachabilityService.DeleteConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(ReachabilityService.prototype.deleteConnectivityTest = function deleteConnectivityTest(request, callback) { - return this.rpcCall(deleteConnectivityTest, $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); - }, "name", { value: "DeleteConnectivityTest" }); - - /** - * Calls DeleteConnectivityTest. - * @function deleteConnectivityTest - * @memberof google.cloud.networkmanagement.v1.ReachabilityService - * @instance - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} request DeleteConnectivityTestRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - return ReachabilityService; - })(); - - v1.ListConnectivityTestsRequest = (function() { - - /** - * Properties of a ListConnectivityTestsRequest. - * @memberof google.cloud.networkmanagement.v1 - * @interface IListConnectivityTestsRequest - * @property {string|null} [parent] ListConnectivityTestsRequest parent - * @property {number|null} [pageSize] ListConnectivityTestsRequest pageSize - * @property {string|null} [pageToken] ListConnectivityTestsRequest pageToken - * @property {string|null} [filter] ListConnectivityTestsRequest filter - * @property {string|null} [orderBy] ListConnectivityTestsRequest orderBy - */ - - /** - * Constructs a new ListConnectivityTestsRequest. - * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a ListConnectivityTestsRequest. - * @implements IListConnectivityTestsRequest - * @constructor - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest=} [properties] Properties to set - */ - function ListConnectivityTestsRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * ListConnectivityTestsRequest parent. - * @member {string} parent - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @instance - */ - ListConnectivityTestsRequest.prototype.parent = ""; - - /** - * ListConnectivityTestsRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @instance - */ - ListConnectivityTestsRequest.prototype.pageSize = 0; - - /** - * ListConnectivityTestsRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @instance - */ - ListConnectivityTestsRequest.prototype.pageToken = ""; - - /** - * ListConnectivityTestsRequest filter. - * @member {string} filter - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @instance - */ - ListConnectivityTestsRequest.prototype.filter = ""; - - /** - * ListConnectivityTestsRequest orderBy. - * @member {string} orderBy - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @instance - */ - ListConnectivityTestsRequest.prototype.orderBy = ""; - - /** - * Creates a new ListConnectivityTestsRequest instance using the specified properties. + * Creates a new LoadBalancerBackendInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest instance + * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo instance */ - ListConnectivityTestsRequest.create = function create(properties) { - return new ListConnectivityTestsRequest(properties); + LoadBalancerBackendInfo.create = function create(properties) { + return new LoadBalancerBackendInfo(properties); }; /** - * Encodes the specified ListConnectivityTestsRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsRequest.verify|verify} messages. + * Encodes the specified LoadBalancerBackendInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} message ListConnectivityTestsRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo} message LoadBalancerBackendInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListConnectivityTestsRequest.encode = function encode(message, writer) { + LoadBalancerBackendInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); - if (message.filter != null && Object.hasOwnProperty.call(message, "filter")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.filter); - if (message.orderBy != null && Object.hasOwnProperty.call(message, "orderBy")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.orderBy); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.instanceUri != null && Object.hasOwnProperty.call(message, "instanceUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.instanceUri); + if (message.backendServiceUri != null && Object.hasOwnProperty.call(message, "backendServiceUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.backendServiceUri); + if (message.instanceGroupUri != null && Object.hasOwnProperty.call(message, "instanceGroupUri")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.instanceGroupUri); + if (message.networkEndpointGroupUri != null && Object.hasOwnProperty.call(message, "networkEndpointGroupUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.networkEndpointGroupUri); + if (message.healthCheckUri != null && Object.hasOwnProperty.call(message, "healthCheckUri")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.healthCheckUri); + if (message.healthCheckFirewallsConfigState != null && Object.hasOwnProperty.call(message, "healthCheckFirewallsConfigState")) + writer.uint32(/* id 7, wireType 0 =*/56).int32(message.healthCheckFirewallsConfigState); + if (message.backendBucketUri != null && Object.hasOwnProperty.call(message, "backendBucketUri")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.backendBucketUri); + if (message.pscServiceAttachmentUri != null && Object.hasOwnProperty.call(message, "pscServiceAttachmentUri")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.pscServiceAttachmentUri); + if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.pscGoogleApiTarget); return writer; }; /** - * Encodes the specified ListConnectivityTestsRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsRequest.verify|verify} messages. + * Encodes the specified LoadBalancerBackendInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} message ListConnectivityTestsRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ILoadBalancerBackendInfo} message LoadBalancerBackendInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListConnectivityTestsRequest.encodeDelimited = function encodeDelimited(message, writer) { + LoadBalancerBackendInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListConnectivityTestsRequest message from the specified reader or buffer. + * Decodes a LoadBalancerBackendInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest + * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListConnectivityTestsRequest.decode = function decode(reader, length) { + LoadBalancerBackendInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.name = reader.string(); break; } case 2: { - message.pageSize = reader.int32(); + message.instanceUri = reader.string(); break; } case 3: { - message.pageToken = reader.string(); + message.backendServiceUri = reader.string(); break; } case 4: { - message.filter = reader.string(); + message.instanceGroupUri = reader.string(); break; } case 5: { - message.orderBy = reader.string(); + message.networkEndpointGroupUri = reader.string(); break; } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ListConnectivityTestsRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + case 8: { + message.backendBucketUri = reader.string(); + break; + } + case 9: { + message.pscServiceAttachmentUri = reader.string(); + break; + } + case 10: { + message.pscGoogleApiTarget = reader.string(); + break; + } + case 6: { + message.healthCheckUri = reader.string(); + break; + } + case 7: { + message.healthCheckFirewallsConfigState = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a LoadBalancerBackendInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListConnectivityTestsRequest.decodeDelimited = function decodeDelimited(reader) { + LoadBalancerBackendInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListConnectivityTestsRequest message. + * Verifies a LoadBalancerBackendInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListConnectivityTestsRequest.verify = function verify(message) { + LoadBalancerBackendInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; - if (message.filter != null && message.hasOwnProperty("filter")) - if (!$util.isString(message.filter)) - return "filter: string expected"; - if (message.orderBy != null && message.hasOwnProperty("orderBy")) - if (!$util.isString(message.orderBy)) - return "orderBy: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.instanceUri != null && message.hasOwnProperty("instanceUri")) + if (!$util.isString(message.instanceUri)) + return "instanceUri: string expected"; + if (message.backendServiceUri != null && message.hasOwnProperty("backendServiceUri")) + if (!$util.isString(message.backendServiceUri)) + return "backendServiceUri: string expected"; + if (message.instanceGroupUri != null && message.hasOwnProperty("instanceGroupUri")) + if (!$util.isString(message.instanceGroupUri)) + return "instanceGroupUri: string expected"; + if (message.networkEndpointGroupUri != null && message.hasOwnProperty("networkEndpointGroupUri")) + if (!$util.isString(message.networkEndpointGroupUri)) + return "networkEndpointGroupUri: string expected"; + if (message.backendBucketUri != null && message.hasOwnProperty("backendBucketUri")) + if (!$util.isString(message.backendBucketUri)) + return "backendBucketUri: string expected"; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + if (!$util.isString(message.pscServiceAttachmentUri)) + return "pscServiceAttachmentUri: string expected"; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + if (!$util.isString(message.pscGoogleApiTarget)) + return "pscGoogleApiTarget: string expected"; + if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) + if (!$util.isString(message.healthCheckUri)) + return "healthCheckUri: string expected"; + if (message.healthCheckFirewallsConfigState != null && message.hasOwnProperty("healthCheckFirewallsConfigState")) + switch (message.healthCheckFirewallsConfigState) { + default: + return "healthCheckFirewallsConfigState: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + break; + } return null; }; /** - * Creates a ListConnectivityTestsRequest message from a plain object. Also converts values to their respective internal types. + * Creates a LoadBalancerBackendInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest + * @returns {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} LoadBalancerBackendInfo */ - ListConnectivityTestsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest) + LoadBalancerBackendInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); - if (object.filter != null) - message.filter = String(object.filter); - if (object.orderBy != null) - message.orderBy = String(object.orderBy); + var message = new $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo(); + if (object.name != null) + message.name = String(object.name); + if (object.instanceUri != null) + message.instanceUri = String(object.instanceUri); + if (object.backendServiceUri != null) + message.backendServiceUri = String(object.backendServiceUri); + if (object.instanceGroupUri != null) + message.instanceGroupUri = String(object.instanceGroupUri); + if (object.networkEndpointGroupUri != null) + message.networkEndpointGroupUri = String(object.networkEndpointGroupUri); + if (object.backendBucketUri != null) + message.backendBucketUri = String(object.backendBucketUri); + if (object.pscServiceAttachmentUri != null) + message.pscServiceAttachmentUri = String(object.pscServiceAttachmentUri); + if (object.pscGoogleApiTarget != null) + message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); + if (object.healthCheckUri != null) + message.healthCheckUri = String(object.healthCheckUri); + switch (object.healthCheckFirewallsConfigState) { + default: + if (typeof object.healthCheckFirewallsConfigState === "number") { + message.healthCheckFirewallsConfigState = object.healthCheckFirewallsConfigState; + break; + } + break; + case "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED": + case 0: + message.healthCheckFirewallsConfigState = 0; + break; + case "FIREWALLS_CONFIGURED": + case 1: + message.healthCheckFirewallsConfigState = 1; + break; + case "FIREWALLS_PARTIALLY_CONFIGURED": + case 2: + message.healthCheckFirewallsConfigState = 2; + break; + case "FIREWALLS_NOT_CONFIGURED": + case 3: + message.healthCheckFirewallsConfigState = 3; + break; + case "FIREWALLS_UNSUPPORTED": + case 4: + message.healthCheckFirewallsConfigState = 4; + break; + } return message; }; /** - * Creates a plain object from a ListConnectivityTestsRequest message. Also converts values to other types if specified. + * Creates a plain object from a LoadBalancerBackendInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static - * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} message ListConnectivityTestsRequest + * @param {google.cloud.networkmanagement.v1.LoadBalancerBackendInfo} message LoadBalancerBackendInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListConnectivityTestsRequest.toObject = function toObject(message, options) { + LoadBalancerBackendInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; - object.filter = ""; - object.orderBy = ""; + object.name = ""; + object.instanceUri = ""; + object.backendServiceUri = ""; + object.instanceGroupUri = ""; + object.networkEndpointGroupUri = ""; + object.healthCheckUri = ""; + object.healthCheckFirewallsConfigState = options.enums === String ? "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED" : 0; + object.backendBucketUri = ""; + object.pscServiceAttachmentUri = ""; + object.pscGoogleApiTarget = ""; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; - if (message.filter != null && message.hasOwnProperty("filter")) - object.filter = message.filter; - if (message.orderBy != null && message.hasOwnProperty("orderBy")) - object.orderBy = message.orderBy; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.instanceUri != null && message.hasOwnProperty("instanceUri")) + object.instanceUri = message.instanceUri; + if (message.backendServiceUri != null && message.hasOwnProperty("backendServiceUri")) + object.backendServiceUri = message.backendServiceUri; + if (message.instanceGroupUri != null && message.hasOwnProperty("instanceGroupUri")) + object.instanceGroupUri = message.instanceGroupUri; + if (message.networkEndpointGroupUri != null && message.hasOwnProperty("networkEndpointGroupUri")) + object.networkEndpointGroupUri = message.networkEndpointGroupUri; + if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) + object.healthCheckUri = message.healthCheckUri; + if (message.healthCheckFirewallsConfigState != null && message.hasOwnProperty("healthCheckFirewallsConfigState")) + object.healthCheckFirewallsConfigState = options.enums === String ? $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState[message.healthCheckFirewallsConfigState] === undefined ? message.healthCheckFirewallsConfigState : $root.google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState[message.healthCheckFirewallsConfigState] : message.healthCheckFirewallsConfigState; + if (message.backendBucketUri != null && message.hasOwnProperty("backendBucketUri")) + object.backendBucketUri = message.backendBucketUri; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + object.pscServiceAttachmentUri = message.pscServiceAttachmentUri; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + object.pscGoogleApiTarget = message.pscGoogleApiTarget; return object; }; /** - * Converts this ListConnectivityTestsRequest to JSON. + * Converts this LoadBalancerBackendInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @instance * @returns {Object.} JSON object */ - ListConnectivityTestsRequest.prototype.toJSON = function toJSON() { + LoadBalancerBackendInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListConnectivityTestsRequest + * Gets the default type url for LoadBalancerBackendInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @memberof google.cloud.networkmanagement.v1.LoadBalancerBackendInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListConnectivityTestsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + LoadBalancerBackendInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ListConnectivityTestsRequest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.LoadBalancerBackendInfo"; }; - return ListConnectivityTestsRequest; - })(); - - v1.ListConnectivityTestsResponse = (function() { - /** - * Properties of a ListConnectivityTestsResponse. - * @memberof google.cloud.networkmanagement.v1 - * @interface IListConnectivityTestsResponse - * @property {Array.|null} [resources] ListConnectivityTestsResponse resources - * @property {string|null} [nextPageToken] ListConnectivityTestsResponse nextPageToken - * @property {Array.|null} [unreachable] ListConnectivityTestsResponse unreachable + * HealthCheckFirewallsConfigState enum. + * @name google.cloud.networkmanagement.v1.LoadBalancerBackendInfo.HealthCheckFirewallsConfigState + * @enum {number} + * @property {number} HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED=0 HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED value + * @property {number} FIREWALLS_CONFIGURED=1 FIREWALLS_CONFIGURED value + * @property {number} FIREWALLS_PARTIALLY_CONFIGURED=2 FIREWALLS_PARTIALLY_CONFIGURED value + * @property {number} FIREWALLS_NOT_CONFIGURED=3 FIREWALLS_NOT_CONFIGURED value + * @property {number} FIREWALLS_UNSUPPORTED=4 FIREWALLS_UNSUPPORTED value */ - - /** - * Constructs a new ListConnectivityTestsResponse. - * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a ListConnectivityTestsResponse. - * @implements IListConnectivityTestsResponse + LoadBalancerBackendInfo.HealthCheckFirewallsConfigState = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "HEALTH_CHECK_FIREWALLS_CONFIG_STATE_UNSPECIFIED"] = 0; + values[valuesById[1] = "FIREWALLS_CONFIGURED"] = 1; + values[valuesById[2] = "FIREWALLS_PARTIALLY_CONFIGURED"] = 2; + values[valuesById[3] = "FIREWALLS_NOT_CONFIGURED"] = 3; + values[valuesById[4] = "FIREWALLS_UNSUPPORTED"] = 4; + return values; + })(); + + return LoadBalancerBackendInfo; + })(); + + /** + * LoadBalancerType enum. + * @name google.cloud.networkmanagement.v1.LoadBalancerType + * @enum {number} + * @property {number} LOAD_BALANCER_TYPE_UNSPECIFIED=0 LOAD_BALANCER_TYPE_UNSPECIFIED value + * @property {number} HTTPS_ADVANCED_LOAD_BALANCER=1 HTTPS_ADVANCED_LOAD_BALANCER value + * @property {number} HTTPS_LOAD_BALANCER=2 HTTPS_LOAD_BALANCER value + * @property {number} REGIONAL_HTTPS_LOAD_BALANCER=3 REGIONAL_HTTPS_LOAD_BALANCER value + * @property {number} INTERNAL_HTTPS_LOAD_BALANCER=4 INTERNAL_HTTPS_LOAD_BALANCER value + * @property {number} SSL_PROXY_LOAD_BALANCER=5 SSL_PROXY_LOAD_BALANCER value + * @property {number} TCP_PROXY_LOAD_BALANCER=6 TCP_PROXY_LOAD_BALANCER value + * @property {number} INTERNAL_TCP_PROXY_LOAD_BALANCER=7 INTERNAL_TCP_PROXY_LOAD_BALANCER value + * @property {number} NETWORK_LOAD_BALANCER=8 NETWORK_LOAD_BALANCER value + * @property {number} LEGACY_NETWORK_LOAD_BALANCER=9 LEGACY_NETWORK_LOAD_BALANCER value + * @property {number} TCP_UDP_INTERNAL_LOAD_BALANCER=10 TCP_UDP_INTERNAL_LOAD_BALANCER value + */ + v1.LoadBalancerType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "LOAD_BALANCER_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "HTTPS_ADVANCED_LOAD_BALANCER"] = 1; + values[valuesById[2] = "HTTPS_LOAD_BALANCER"] = 2; + values[valuesById[3] = "REGIONAL_HTTPS_LOAD_BALANCER"] = 3; + values[valuesById[4] = "INTERNAL_HTTPS_LOAD_BALANCER"] = 4; + values[valuesById[5] = "SSL_PROXY_LOAD_BALANCER"] = 5; + values[valuesById[6] = "TCP_PROXY_LOAD_BALANCER"] = 6; + values[valuesById[7] = "INTERNAL_TCP_PROXY_LOAD_BALANCER"] = 7; + values[valuesById[8] = "NETWORK_LOAD_BALANCER"] = 8; + values[valuesById[9] = "LEGACY_NETWORK_LOAD_BALANCER"] = 9; + values[valuesById[10] = "TCP_UDP_INTERNAL_LOAD_BALANCER"] = 10; + return values; + })(); + + v1.StorageBucketInfo = (function() { + + /** + * Properties of a StorageBucketInfo. + * @memberof google.cloud.networkmanagement.v1 + * @interface IStorageBucketInfo + * @property {string|null} [bucket] StorageBucketInfo bucket + */ + + /** + * Constructs a new StorageBucketInfo. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents a StorageBucketInfo. + * @implements IStorageBucketInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo=} [properties] Properties to set */ - function ListConnectivityTestsResponse(properties) { - this.resources = []; - this.unreachable = []; + function StorageBucketInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15626,109 +16246,75 @@ } /** - * ListConnectivityTestsResponse resources. - * @member {Array.} resources - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse - * @instance - */ - ListConnectivityTestsResponse.prototype.resources = $util.emptyArray; - - /** - * ListConnectivityTestsResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse - * @instance - */ - ListConnectivityTestsResponse.prototype.nextPageToken = ""; - - /** - * ListConnectivityTestsResponse unreachable. - * @member {Array.} unreachable - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * StorageBucketInfo bucket. + * @member {string} bucket + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @instance */ - ListConnectivityTestsResponse.prototype.unreachable = $util.emptyArray; + StorageBucketInfo.prototype.bucket = ""; /** - * Creates a new ListConnectivityTestsResponse instance using the specified properties. + * Creates a new StorageBucketInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse instance + * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo instance */ - ListConnectivityTestsResponse.create = function create(properties) { - return new ListConnectivityTestsResponse(properties); + StorageBucketInfo.create = function create(properties) { + return new StorageBucketInfo(properties); }; /** - * Encodes the specified ListConnectivityTestsResponse message. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.verify|verify} messages. + * Encodes the specified StorageBucketInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.StorageBucketInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse} message ListConnectivityTestsResponse message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo} message StorageBucketInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListConnectivityTestsResponse.encode = function encode(message, writer) { + StorageBucketInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.resources != null && message.resources.length) - for (var i = 0; i < message.resources.length; ++i) - $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resources[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); - if (message.unreachable != null && message.unreachable.length) - for (var i = 0; i < message.unreachable.length; ++i) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.unreachable[i]); + if (message.bucket != null && Object.hasOwnProperty.call(message, "bucket")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.bucket); return writer; }; /** - * Encodes the specified ListConnectivityTestsResponse message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.verify|verify} messages. + * Encodes the specified StorageBucketInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.StorageBucketInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static - * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse} message ListConnectivityTestsResponse message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IStorageBucketInfo} message StorageBucketInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListConnectivityTestsResponse.encodeDelimited = function encodeDelimited(message, writer) { + StorageBucketInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListConnectivityTestsResponse message from the specified reader or buffer. + * Decodes a StorageBucketInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse + * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListConnectivityTestsResponse.decode = function decode(reader, length) { + StorageBucketInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.StorageBucketInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.resources && message.resources.length)) - message.resources = []; - message.resources.push($root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32())); - break; - } - case 2: { - message.nextPageToken = reader.string(); - break; - } - case 3: { - if (!(message.unreachable && message.unreachable.length)) - message.unreachable = []; - message.unreachable.push(reader.string()); + message.bucket = reader.string(); break; } default: @@ -15740,169 +16326,122 @@ }; /** - * Decodes a ListConnectivityTestsResponse message from the specified reader or buffer, length delimited. + * Decodes a StorageBucketInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse + * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListConnectivityTestsResponse.decodeDelimited = function decodeDelimited(reader) { + StorageBucketInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListConnectivityTestsResponse message. + * Verifies a StorageBucketInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListConnectivityTestsResponse.verify = function verify(message) { + StorageBucketInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.resources != null && message.hasOwnProperty("resources")) { - if (!Array.isArray(message.resources)) - return "resources: array expected"; - for (var i = 0; i < message.resources.length; ++i) { - var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resources[i]); - if (error) - return "resources." + error; - } - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; - if (message.unreachable != null && message.hasOwnProperty("unreachable")) { - if (!Array.isArray(message.unreachable)) - return "unreachable: array expected"; - for (var i = 0; i < message.unreachable.length; ++i) - if (!$util.isString(message.unreachable[i])) - return "unreachable: string[] expected"; - } + if (message.bucket != null && message.hasOwnProperty("bucket")) + if (!$util.isString(message.bucket)) + return "bucket: string expected"; return null; }; /** - * Creates a ListConnectivityTestsResponse message from a plain object. Also converts values to their respective internal types. + * Creates a StorageBucketInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse + * @returns {google.cloud.networkmanagement.v1.StorageBucketInfo} StorageBucketInfo */ - ListConnectivityTestsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse) + StorageBucketInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.StorageBucketInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse(); - if (object.resources) { - if (!Array.isArray(object.resources)) - throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.resources: array expected"); - message.resources = []; - for (var i = 0; i < object.resources.length; ++i) { - if (typeof object.resources[i] !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.resources: object expected"); - message.resources[i] = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resources[i]); - } - } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); - if (object.unreachable) { - if (!Array.isArray(object.unreachable)) - throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.unreachable: array expected"); - message.unreachable = []; - for (var i = 0; i < object.unreachable.length; ++i) - message.unreachable[i] = String(object.unreachable[i]); - } + var message = new $root.google.cloud.networkmanagement.v1.StorageBucketInfo(); + if (object.bucket != null) + message.bucket = String(object.bucket); return message; }; /** - * Creates a plain object from a ListConnectivityTestsResponse message. Also converts values to other types if specified. + * Creates a plain object from a StorageBucketInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static - * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} message ListConnectivityTestsResponse + * @param {google.cloud.networkmanagement.v1.StorageBucketInfo} message StorageBucketInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListConnectivityTestsResponse.toObject = function toObject(message, options) { + StorageBucketInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.resources = []; - object.unreachable = []; - } if (options.defaults) - object.nextPageToken = ""; - if (message.resources && message.resources.length) { - object.resources = []; - for (var j = 0; j < message.resources.length; ++j) - object.resources[j] = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resources[j], options); - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; - if (message.unreachable && message.unreachable.length) { - object.unreachable = []; - for (var j = 0; j < message.unreachable.length; ++j) - object.unreachable[j] = message.unreachable[j]; - } + object.bucket = ""; + if (message.bucket != null && message.hasOwnProperty("bucket")) + object.bucket = message.bucket; return object; }; /** - * Converts this ListConnectivityTestsResponse to JSON. + * Converts this StorageBucketInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @instance * @returns {Object.} JSON object */ - ListConnectivityTestsResponse.prototype.toJSON = function toJSON() { + StorageBucketInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListConnectivityTestsResponse + * Gets the default type url for StorageBucketInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @memberof google.cloud.networkmanagement.v1.StorageBucketInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListConnectivityTestsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + StorageBucketInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ListConnectivityTestsResponse"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.StorageBucketInfo"; }; - return ListConnectivityTestsResponse; + return StorageBucketInfo; })(); - v1.GetConnectivityTestRequest = (function() { + v1.ServerlessNegInfo = (function() { /** - * Properties of a GetConnectivityTestRequest. + * Properties of a ServerlessNegInfo. * @memberof google.cloud.networkmanagement.v1 - * @interface IGetConnectivityTestRequest - * @property {string|null} [name] GetConnectivityTestRequest name + * @interface IServerlessNegInfo + * @property {string|null} [negUri] ServerlessNegInfo negUri */ /** - * Constructs a new GetConnectivityTestRequest. + * Constructs a new ServerlessNegInfo. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a GetConnectivityTestRequest. - * @implements IGetConnectivityTestRequest + * @classdesc Represents a ServerlessNegInfo. + * @implements IServerlessNegInfo * @constructor - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IServerlessNegInfo=} [properties] Properties to set */ - function GetConnectivityTestRequest(properties) { + function ServerlessNegInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15910,75 +16449,75 @@ } /** - * GetConnectivityTestRequest name. - * @member {string} name - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * ServerlessNegInfo negUri. + * @member {string} negUri + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @instance */ - GetConnectivityTestRequest.prototype.name = ""; + ServerlessNegInfo.prototype.negUri = ""; /** - * Creates a new GetConnectivityTestRequest instance using the specified properties. + * Creates a new ServerlessNegInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest instance + * @param {google.cloud.networkmanagement.v1.IServerlessNegInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.ServerlessNegInfo} ServerlessNegInfo instance */ - GetConnectivityTestRequest.create = function create(properties) { - return new GetConnectivityTestRequest(properties); + ServerlessNegInfo.create = function create(properties) { + return new ServerlessNegInfo(properties); }; /** - * Encodes the specified GetConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.GetConnectivityTestRequest.verify|verify} messages. + * Encodes the specified ServerlessNegInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1.ServerlessNegInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} message GetConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IServerlessNegInfo} message ServerlessNegInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetConnectivityTestRequest.encode = function encode(message, writer) { + ServerlessNegInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.negUri != null && Object.hasOwnProperty.call(message, "negUri")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.negUri); return writer; }; /** - * Encodes the specified GetConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.GetConnectivityTestRequest.verify|verify} messages. + * Encodes the specified ServerlessNegInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ServerlessNegInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static - * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} message GetConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IServerlessNegInfo} message ServerlessNegInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + ServerlessNegInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetConnectivityTestRequest message from the specified reader or buffer. + * Decodes a ServerlessNegInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ServerlessNegInfo} ServerlessNegInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetConnectivityTestRequest.decode = function decode(reader, length) { + ServerlessNegInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ServerlessNegInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.negUri = reader.string(); break; } default: @@ -15990,378 +16529,359 @@ }; /** - * Decodes a GetConnectivityTestRequest message from the specified reader or buffer, length delimited. + * Decodes a ServerlessNegInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ServerlessNegInfo} ServerlessNegInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + ServerlessNegInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetConnectivityTestRequest message. + * Verifies a ServerlessNegInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetConnectivityTestRequest.verify = function verify(message) { + ServerlessNegInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.negUri != null && message.hasOwnProperty("negUri")) + if (!$util.isString(message.negUri)) + return "negUri: string expected"; return null; }; /** - * Creates a GetConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ServerlessNegInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ServerlessNegInfo} ServerlessNegInfo */ - GetConnectivityTestRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest) + ServerlessNegInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.ServerlessNegInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.networkmanagement.v1.ServerlessNegInfo(); + if (object.negUri != null) + message.negUri = String(object.negUri); return message; }; /** - * Creates a plain object from a GetConnectivityTestRequest message. Also converts values to other types if specified. + * Creates a plain object from a ServerlessNegInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static - * @param {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} message GetConnectivityTestRequest + * @param {google.cloud.networkmanagement.v1.ServerlessNegInfo} message ServerlessNegInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetConnectivityTestRequest.toObject = function toObject(message, options) { + ServerlessNegInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.negUri = ""; + if (message.negUri != null && message.hasOwnProperty("negUri")) + object.negUri = message.negUri; return object; }; /** - * Converts this GetConnectivityTestRequest to JSON. + * Converts this ServerlessNegInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @instance * @returns {Object.} JSON object */ - GetConnectivityTestRequest.prototype.toJSON = function toJSON() { + ServerlessNegInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetConnectivityTestRequest + * Gets the default type url for ServerlessNegInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ServerlessNegInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ServerlessNegInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.GetConnectivityTestRequest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ServerlessNegInfo"; }; - return GetConnectivityTestRequest; + return ServerlessNegInfo; })(); - v1.CreateConnectivityTestRequest = (function() { + v1.ReachabilityService = (function() { /** - * Properties of a CreateConnectivityTestRequest. + * Constructs a new ReachabilityService service. * @memberof google.cloud.networkmanagement.v1 - * @interface ICreateConnectivityTestRequest - * @property {string|null} [parent] CreateConnectivityTestRequest parent - * @property {string|null} [testId] CreateConnectivityTestRequest testId - * @property {google.cloud.networkmanagement.v1.IConnectivityTest|null} [resource] CreateConnectivityTestRequest resource + * @classdesc Represents a ReachabilityService + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited */ + function ReachabilityService(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } + + (ReachabilityService.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = ReachabilityService; /** - * Constructs a new CreateConnectivityTestRequest. - * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a CreateConnectivityTestRequest. - * @implements ICreateConnectivityTestRequest - * @constructor - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest=} [properties] Properties to set + * Creates new ReachabilityService service using the specified rpc implementation. + * @function create + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @static + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {ReachabilityService} RPC service. Useful where requests and/or responses are streamed. */ - function CreateConnectivityTestRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + ReachabilityService.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); + }; /** - * CreateConnectivityTestRequest parent. - * @member {string} parent - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|listConnectivityTests}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef ListConnectivityTestsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} [response] ListConnectivityTestsResponse + */ + + /** + * Calls ListConnectivityTests. + * @function listConnectivityTests + * @memberof google.cloud.networkmanagement.v1.ReachabilityService * @instance + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} request ListConnectivityTestsRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.ListConnectivityTestsCallback} callback Node-style callback called with the error, if any, and ListConnectivityTestsResponse + * @returns {undefined} + * @variation 1 */ - CreateConnectivityTestRequest.prototype.parent = ""; + Object.defineProperty(ReachabilityService.prototype.listConnectivityTests = function listConnectivityTests(request, callback) { + return this.rpcCall(listConnectivityTests, $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest, $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse, request, callback); + }, "name", { value: "ListConnectivityTests" }); /** - * CreateConnectivityTestRequest testId. - * @member {string} testId - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest + * Calls ListConnectivityTests. + * @function listConnectivityTests + * @memberof google.cloud.networkmanagement.v1.ReachabilityService * @instance + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} request ListConnectivityTestsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateConnectivityTestRequest.prototype.testId = ""; /** - * CreateConnectivityTestRequest resource. - * @member {google.cloud.networkmanagement.v1.IConnectivityTest|null|undefined} resource - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|getConnectivityTest}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef GetConnectivityTestCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.networkmanagement.v1.ConnectivityTest} [response] ConnectivityTest + */ + + /** + * Calls GetConnectivityTest. + * @function getConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService * @instance + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} request GetConnectivityTestRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.GetConnectivityTestCallback} callback Node-style callback called with the error, if any, and ConnectivityTest + * @returns {undefined} + * @variation 1 */ - CreateConnectivityTestRequest.prototype.resource = null; + Object.defineProperty(ReachabilityService.prototype.getConnectivityTest = function getConnectivityTest(request, callback) { + return this.rpcCall(getConnectivityTest, $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest, $root.google.cloud.networkmanagement.v1.ConnectivityTest, request, callback); + }, "name", { value: "GetConnectivityTest" }); /** - * Creates a new CreateConnectivityTestRequest instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest instance + * Calls GetConnectivityTest. + * @function getConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} request GetConnectivityTestRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateConnectivityTestRequest.create = function create(properties) { - return new CreateConnectivityTestRequest(properties); - }; /** - * Encodes the specified CreateConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} message CreateConnectivityTestRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|createConnectivityTest}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef CreateConnectivityTestCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation */ - CreateConnectivityTestRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.testId != null && Object.hasOwnProperty.call(message, "testId")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.testId); - if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) - $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resource, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - return writer; - }; /** - * Encodes the specified CreateConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} message CreateConnectivityTestRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls CreateConnectivityTest. + * @function createConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} request CreateConnectivityTestRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.CreateConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 */ - CreateConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Object.defineProperty(ReachabilityService.prototype.createConnectivityTest = function createConnectivityTest(request, callback) { + return this.rpcCall(createConnectivityTest, $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "CreateConnectivityTest" }); /** - * Decodes a CreateConnectivityTestRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls CreateConnectivityTest. + * @function createConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} request CreateConnectivityTestRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateConnectivityTestRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.parent = reader.string(); - break; - } - case 2: { - message.testId = reader.string(); - break; - } - case 3: { - message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a CreateConnectivityTestRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|updateConnectivityTest}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef UpdateConnectivityTestCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation */ - CreateConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies a CreateConnectivityTestRequest message. - * @function verify - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls UpdateConnectivityTest. + * @function updateConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} request UpdateConnectivityTestRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.UpdateConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 */ - CreateConnectivityTestRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.testId != null && message.hasOwnProperty("testId")) - if (!$util.isString(message.testId)) - return "testId: string expected"; - if (message.resource != null && message.hasOwnProperty("resource")) { - var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resource); - if (error) - return "resource." + error; - } - return null; - }; + Object.defineProperty(ReachabilityService.prototype.updateConnectivityTest = function updateConnectivityTest(request, callback) { + return this.rpcCall(updateConnectivityTest, $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "UpdateConnectivityTest" }); /** - * Creates a CreateConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest + * Calls UpdateConnectivityTest. + * @function updateConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} request UpdateConnectivityTestRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateConnectivityTestRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest) - return object; - var message = new $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.testId != null) - message.testId = String(object.testId); - if (object.resource != null) { - if (typeof object.resource !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.resource: object expected"); - message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resource); - } - return message; - }; /** - * Creates a plain object from a CreateConnectivityTestRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} message CreateConnectivityTestRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|rerunConnectivityTest}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef RerunConnectivityTestCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation */ - CreateConnectivityTestRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.parent = ""; - object.testId = ""; - object.resource = null; - } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.testId != null && message.hasOwnProperty("testId")) - object.testId = message.testId; - if (message.resource != null && message.hasOwnProperty("resource")) - object.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resource, options); - return object; - }; /** - * Converts this CreateConnectivityTestRequest to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest + * Calls RerunConnectivityTest. + * @function rerunConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService * @instance - * @returns {Object.} JSON object + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} request RerunConnectivityTestRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.RerunConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 */ - CreateConnectivityTestRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Object.defineProperty(ReachabilityService.prototype.rerunConnectivityTest = function rerunConnectivityTest(request, callback) { + return this.rpcCall(rerunConnectivityTest, $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "RerunConnectivityTest" }); /** - * Gets the default type url for CreateConnectivityTestRequest - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Calls RerunConnectivityTest. + * @function rerunConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} request RerunConnectivityTestRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CreateConnectivityTestRequest"; - }; - return CreateConnectivityTestRequest; + /** + * Callback as used by {@link google.cloud.networkmanagement.v1.ReachabilityService|deleteConnectivityTest}. + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @typedef DeleteConnectivityTestCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation + */ + + /** + * Calls DeleteConnectivityTest. + * @function deleteConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} request DeleteConnectivityTestRequest message or plain object + * @param {google.cloud.networkmanagement.v1.ReachabilityService.DeleteConnectivityTestCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(ReachabilityService.prototype.deleteConnectivityTest = function deleteConnectivityTest(request, callback) { + return this.rpcCall(deleteConnectivityTest, $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "DeleteConnectivityTest" }); + + /** + * Calls DeleteConnectivityTest. + * @function deleteConnectivityTest + * @memberof google.cloud.networkmanagement.v1.ReachabilityService + * @instance + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} request DeleteConnectivityTestRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + return ReachabilityService; })(); - v1.UpdateConnectivityTestRequest = (function() { + v1.ListConnectivityTestsRequest = (function() { /** - * Properties of an UpdateConnectivityTestRequest. + * Properties of a ListConnectivityTestsRequest. * @memberof google.cloud.networkmanagement.v1 - * @interface IUpdateConnectivityTestRequest - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateConnectivityTestRequest updateMask - * @property {google.cloud.networkmanagement.v1.IConnectivityTest|null} [resource] UpdateConnectivityTestRequest resource + * @interface IListConnectivityTestsRequest + * @property {string|null} [parent] ListConnectivityTestsRequest parent + * @property {number|null} [pageSize] ListConnectivityTestsRequest pageSize + * @property {string|null} [pageToken] ListConnectivityTestsRequest pageToken + * @property {string|null} [filter] ListConnectivityTestsRequest filter + * @property {string|null} [orderBy] ListConnectivityTestsRequest orderBy */ /** - * Constructs a new UpdateConnectivityTestRequest. + * Constructs a new ListConnectivityTestsRequest. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents an UpdateConnectivityTestRequest. - * @implements IUpdateConnectivityTestRequest + * @classdesc Represents a ListConnectivityTestsRequest. + * @implements IListConnectivityTestsRequest * @constructor - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest=} [properties] Properties to set */ - function UpdateConnectivityTestRequest(properties) { + function ListConnectivityTestsRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -16369,89 +16889,131 @@ } /** - * UpdateConnectivityTestRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * ListConnectivityTestsRequest parent. + * @member {string} parent + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @instance */ - UpdateConnectivityTestRequest.prototype.updateMask = null; + ListConnectivityTestsRequest.prototype.parent = ""; /** - * UpdateConnectivityTestRequest resource. - * @member {google.cloud.networkmanagement.v1.IConnectivityTest|null|undefined} resource - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * ListConnectivityTestsRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @instance */ - UpdateConnectivityTestRequest.prototype.resource = null; + ListConnectivityTestsRequest.prototype.pageSize = 0; /** - * Creates a new UpdateConnectivityTestRequest instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest instance + * ListConnectivityTestsRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @instance */ - UpdateConnectivityTestRequest.create = function create(properties) { - return new UpdateConnectivityTestRequest(properties); - }; + ListConnectivityTestsRequest.prototype.pageToken = ""; /** - * Encodes the specified UpdateConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.verify|verify} messages. + * ListConnectivityTestsRequest filter. + * @member {string} filter + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @instance + */ + ListConnectivityTestsRequest.prototype.filter = ""; + + /** + * ListConnectivityTestsRequest orderBy. + * @member {string} orderBy + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @instance + */ + ListConnectivityTestsRequest.prototype.orderBy = ""; + + /** + * Creates a new ListConnectivityTestsRequest instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest + * @static + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest instance + */ + ListConnectivityTestsRequest.create = function create(properties) { + return new ListConnectivityTestsRequest(properties); + }; + + /** + * Encodes the specified ListConnectivityTestsRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} message UpdateConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} message ListConnectivityTestsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateConnectivityTestRequest.encode = function encode(message, writer) { + ListConnectivityTestsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) - $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.filter != null && Object.hasOwnProperty.call(message, "filter")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.filter); + if (message.orderBy != null && Object.hasOwnProperty.call(message, "orderBy")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.orderBy); return writer; }; /** - * Encodes the specified UpdateConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.verify|verify} messages. + * Encodes the specified ListConnectivityTestsRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static - * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} message UpdateConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsRequest} message ListConnectivityTestsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListConnectivityTestsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateConnectivityTestRequest message from the specified reader or buffer. + * Decodes a ListConnectivityTestsRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateConnectivityTestRequest.decode = function decode(reader, length) { + ListConnectivityTestsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + message.parent = reader.string(); break; } case 2: { - message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32()); + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); + break; + } + case 4: { + message.filter = reader.string(); + break; + } + case 5: { + message.orderBy = reader.string(); break; } default: @@ -16463,141 +17025,159 @@ }; /** - * Decodes an UpdateConnectivityTestRequest message from the specified reader or buffer, length delimited. + * Decodes a ListConnectivityTestsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + ListConnectivityTestsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateConnectivityTestRequest message. + * Verifies a ListConnectivityTestsRequest message. * @function verify - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateConnectivityTestRequest.verify = function verify(message) { + ListConnectivityTestsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } - if (message.resource != null && message.hasOwnProperty("resource")) { - var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resource); - if (error) - return "resource." + error; - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + if (message.filter != null && message.hasOwnProperty("filter")) + if (!$util.isString(message.filter)) + return "filter: string expected"; + if (message.orderBy != null && message.hasOwnProperty("orderBy")) + if (!$util.isString(message.orderBy)) + return "orderBy: string expected"; return null; }; /** - * Creates an UpdateConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListConnectivityTestsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} ListConnectivityTestsRequest */ - UpdateConnectivityTestRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest) + ListConnectivityTestsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest) return object; - var message = new $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest(); - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } - if (object.resource != null) { - if (typeof object.resource !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.resource: object expected"); - message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resource); - } + var message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + if (object.filter != null) + message.filter = String(object.filter); + if (object.orderBy != null) + message.orderBy = String(object.orderBy); return message; }; /** - * Creates a plain object from an UpdateConnectivityTestRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListConnectivityTestsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static - * @param {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} message UpdateConnectivityTestRequest + * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsRequest} message ListConnectivityTestsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateConnectivityTestRequest.toObject = function toObject(message, options) { + ListConnectivityTestsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.updateMask = null; - object.resource = null; + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; + object.filter = ""; + object.orderBy = ""; } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); - if (message.resource != null && message.hasOwnProperty("resource")) - object.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resource, options); + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.filter != null && message.hasOwnProperty("filter")) + object.filter = message.filter; + if (message.orderBy != null && message.hasOwnProperty("orderBy")) + object.orderBy = message.orderBy; return object; }; /** - * Converts this UpdateConnectivityTestRequest to JSON. + * Converts this ListConnectivityTestsRequest to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @instance * @returns {Object.} JSON object */ - UpdateConnectivityTestRequest.prototype.toJSON = function toJSON() { + ListConnectivityTestsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateConnectivityTestRequest + * Gets the default type url for ListConnectivityTestsRequest * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListConnectivityTestsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ListConnectivityTestsRequest"; }; - return UpdateConnectivityTestRequest; + return ListConnectivityTestsRequest; })(); - v1.DeleteConnectivityTestRequest = (function() { + v1.ListConnectivityTestsResponse = (function() { /** - * Properties of a DeleteConnectivityTestRequest. + * Properties of a ListConnectivityTestsResponse. * @memberof google.cloud.networkmanagement.v1 - * @interface IDeleteConnectivityTestRequest - * @property {string|null} [name] DeleteConnectivityTestRequest name + * @interface IListConnectivityTestsResponse + * @property {Array.|null} [resources] ListConnectivityTestsResponse resources + * @property {string|null} [nextPageToken] ListConnectivityTestsResponse nextPageToken + * @property {Array.|null} [unreachable] ListConnectivityTestsResponse unreachable */ /** - * Constructs a new DeleteConnectivityTestRequest. + * Constructs a new ListConnectivityTestsResponse. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a DeleteConnectivityTestRequest. - * @implements IDeleteConnectivityTestRequest + * @classdesc Represents a ListConnectivityTestsResponse. + * @implements IListConnectivityTestsResponse * @constructor - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse=} [properties] Properties to set */ - function DeleteConnectivityTestRequest(properties) { + function ListConnectivityTestsResponse(properties) { + this.resources = []; + this.unreachable = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -16605,75 +17185,109 @@ } /** - * DeleteConnectivityTestRequest name. - * @member {string} name - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * ListConnectivityTestsResponse resources. + * @member {Array.} resources + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @instance */ - DeleteConnectivityTestRequest.prototype.name = ""; + ListConnectivityTestsResponse.prototype.resources = $util.emptyArray; /** - * Creates a new DeleteConnectivityTestRequest instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest instance + * ListConnectivityTestsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @instance */ - DeleteConnectivityTestRequest.create = function create(properties) { - return new DeleteConnectivityTestRequest(properties); - }; + ListConnectivityTestsResponse.prototype.nextPageToken = ""; /** - * Encodes the specified DeleteConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest - * @static - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} message DeleteConnectivityTestRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * ListConnectivityTestsResponse unreachable. + * @member {Array.} unreachable + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @instance */ - DeleteConnectivityTestRequest.encode = function encode(message, writer) { + ListConnectivityTestsResponse.prototype.unreachable = $util.emptyArray; + + /** + * Creates a new ListConnectivityTestsResponse instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @static + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse instance + */ + ListConnectivityTestsResponse.create = function create(properties) { + return new ListConnectivityTestsResponse(properties); + }; + + /** + * Encodes the specified ListConnectivityTestsResponse message. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse + * @static + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse} message ListConnectivityTestsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListConnectivityTestsResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.resources != null && message.resources.length) + for (var i = 0; i < message.resources.length; ++i) + $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resources[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.unreachable != null && message.unreachable.length) + for (var i = 0; i < message.unreachable.length; ++i) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.unreachable[i]); return writer; }; /** - * Encodes the specified DeleteConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest.verify|verify} messages. + * Encodes the specified ListConnectivityTestsResponse message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static - * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} message DeleteConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IListConnectivityTestsResponse} message ListConnectivityTestsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListConnectivityTestsResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteConnectivityTestRequest message from the specified reader or buffer. + * Decodes a ListConnectivityTestsResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteConnectivityTestRequest.decode = function decode(reader, length) { + ListConnectivityTestsResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + if (!(message.resources && message.resources.length)) + message.resources = []; + message.resources.push($root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32())); + break; + } + case 2: { + message.nextPageToken = reader.string(); + break; + } + case 3: { + if (!(message.unreachable && message.unreachable.length)) + message.unreachable = []; + message.unreachable.push(reader.string()); break; } default: @@ -16685,122 +17299,169 @@ }; /** - * Decodes a DeleteConnectivityTestRequest message from the specified reader or buffer, length delimited. + * Decodes a ListConnectivityTestsResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + ListConnectivityTestsResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteConnectivityTestRequest message. + * Verifies a ListConnectivityTestsResponse message. * @function verify - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteConnectivityTestRequest.verify = function verify(message) { + ListConnectivityTestsResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.resources != null && message.hasOwnProperty("resources")) { + if (!Array.isArray(message.resources)) + return "resources: array expected"; + for (var i = 0; i < message.resources.length; ++i) { + var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resources[i]); + if (error) + return "resources." + error; + } + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; + if (message.unreachable != null && message.hasOwnProperty("unreachable")) { + if (!Array.isArray(message.unreachable)) + return "unreachable: array expected"; + for (var i = 0; i < message.unreachable.length; ++i) + if (!$util.isString(message.unreachable[i])) + return "unreachable: string[] expected"; + } return null; }; /** - * Creates a DeleteConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListConnectivityTestsResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} ListConnectivityTestsResponse */ - DeleteConnectivityTestRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest) + ListConnectivityTestsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse) return object; - var message = new $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.networkmanagement.v1.ListConnectivityTestsResponse(); + if (object.resources) { + if (!Array.isArray(object.resources)) + throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.resources: array expected"); + message.resources = []; + for (var i = 0; i < object.resources.length; ++i) { + if (typeof object.resources[i] !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.resources: object expected"); + message.resources[i] = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resources[i]); + } + } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); + if (object.unreachable) { + if (!Array.isArray(object.unreachable)) + throw TypeError(".google.cloud.networkmanagement.v1.ListConnectivityTestsResponse.unreachable: array expected"); + message.unreachable = []; + for (var i = 0; i < object.unreachable.length; ++i) + message.unreachable[i] = String(object.unreachable[i]); + } return message; }; /** - * Creates a plain object from a DeleteConnectivityTestRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListConnectivityTestsResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static - * @param {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} message DeleteConnectivityTestRequest + * @param {google.cloud.networkmanagement.v1.ListConnectivityTestsResponse} message ListConnectivityTestsResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteConnectivityTestRequest.toObject = function toObject(message, options) { + ListConnectivityTestsResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.resources = []; + object.unreachable = []; + } if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.nextPageToken = ""; + if (message.resources && message.resources.length) { + object.resources = []; + for (var j = 0; j < message.resources.length; ++j) + object.resources[j] = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resources[j], options); + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; + if (message.unreachable && message.unreachable.length) { + object.unreachable = []; + for (var j = 0; j < message.unreachable.length; ++j) + object.unreachable[j] = message.unreachable[j]; + } return object; }; /** - * Converts this DeleteConnectivityTestRequest to JSON. + * Converts this ListConnectivityTestsResponse to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @instance * @returns {Object.} JSON object */ - DeleteConnectivityTestRequest.prototype.toJSON = function toJSON() { + ListConnectivityTestsResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteConnectivityTestRequest + * Gets the default type url for ListConnectivityTestsResponse * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.ListConnectivityTestsResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListConnectivityTestsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.ListConnectivityTestsResponse"; }; - return DeleteConnectivityTestRequest; + return ListConnectivityTestsResponse; })(); - v1.RerunConnectivityTestRequest = (function() { + v1.GetConnectivityTestRequest = (function() { /** - * Properties of a RerunConnectivityTestRequest. + * Properties of a GetConnectivityTestRequest. * @memberof google.cloud.networkmanagement.v1 - * @interface IRerunConnectivityTestRequest - * @property {string|null} [name] RerunConnectivityTestRequest name + * @interface IGetConnectivityTestRequest + * @property {string|null} [name] GetConnectivityTestRequest name */ /** - * Constructs a new RerunConnectivityTestRequest. + * Constructs a new GetConnectivityTestRequest. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents a RerunConnectivityTestRequest. - * @implements IRerunConnectivityTestRequest + * @classdesc Represents a GetConnectivityTestRequest. + * @implements IGetConnectivityTestRequest * @constructor - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest=} [properties] Properties to set */ - function RerunConnectivityTestRequest(properties) { + function GetConnectivityTestRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -16808,35 +17469,35 @@ } /** - * RerunConnectivityTestRequest name. + * GetConnectivityTestRequest name. * @member {string} name - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @instance */ - RerunConnectivityTestRequest.prototype.name = ""; + GetConnectivityTestRequest.prototype.name = ""; /** - * Creates a new RerunConnectivityTestRequest instance using the specified properties. + * Creates a new GetConnectivityTestRequest instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest instance + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest instance */ - RerunConnectivityTestRequest.create = function create(properties) { - return new RerunConnectivityTestRequest(properties); + GetConnectivityTestRequest.create = function create(properties) { + return new GetConnectivityTestRequest(properties); }; /** - * Encodes the specified RerunConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.RerunConnectivityTestRequest.verify|verify} messages. + * Encodes the specified GetConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.GetConnectivityTestRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} message RerunConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} message GetConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RerunConnectivityTestRequest.encode = function encode(message, writer) { + GetConnectivityTestRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) @@ -16845,33 +17506,33 @@ }; /** - * Encodes the specified RerunConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RerunConnectivityTestRequest.verify|verify} messages. + * Encodes the specified GetConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.GetConnectivityTestRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} message RerunConnectivityTestRequest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IGetConnectivityTestRequest} message GetConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RerunConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + GetConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a RerunConnectivityTestRequest message from the specified reader or buffer. + * Decodes a GetConnectivityTestRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RerunConnectivityTestRequest.decode = function decode(reader, length) { + GetConnectivityTestRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -16888,30 +17549,30 @@ }; /** - * Decodes a RerunConnectivityTestRequest message from the specified reader or buffer, length delimited. + * Decodes a GetConnectivityTestRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RerunConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + GetConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a RerunConnectivityTestRequest message. + * Verifies a GetConnectivityTestRequest message. * @function verify - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - RerunConnectivityTestRequest.verify = function verify(message) { + GetConnectivityTestRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) @@ -16921,32 +17582,32 @@ }; /** - * Creates a RerunConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * Creates a GetConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest + * @returns {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} GetConnectivityTestRequest */ - RerunConnectivityTestRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest) + GetConnectivityTestRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest) return object; - var message = new $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest(); + var message = new $root.google.cloud.networkmanagement.v1.GetConnectivityTestRequest(); if (object.name != null) message.name = String(object.name); return message; }; /** - * Creates a plain object from a RerunConnectivityTestRequest message. Also converts values to other types if specified. + * Creates a plain object from a GetConnectivityTestRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} message RerunConnectivityTestRequest + * @param {google.cloud.networkmanagement.v1.GetConnectivityTestRequest} message GetConnectivityTestRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - RerunConnectivityTestRequest.toObject = function toObject(message, options) { + GetConnectivityTestRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -16958,58 +17619,54 @@ }; /** - * Converts this RerunConnectivityTestRequest to JSON. + * Converts this GetConnectivityTestRequest to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @instance * @returns {Object.} JSON object */ - RerunConnectivityTestRequest.prototype.toJSON = function toJSON() { + GetConnectivityTestRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for RerunConnectivityTestRequest + * Gets the default type url for GetConnectivityTestRequest * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @memberof google.cloud.networkmanagement.v1.GetConnectivityTestRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - RerunConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.RerunConnectivityTestRequest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.GetConnectivityTestRequest"; }; - return RerunConnectivityTestRequest; + return GetConnectivityTestRequest; })(); - v1.OperationMetadata = (function() { + v1.CreateConnectivityTestRequest = (function() { /** - * Properties of an OperationMetadata. + * Properties of a CreateConnectivityTestRequest. * @memberof google.cloud.networkmanagement.v1 - * @interface IOperationMetadata - * @property {google.protobuf.ITimestamp|null} [createTime] OperationMetadata createTime - * @property {google.protobuf.ITimestamp|null} [endTime] OperationMetadata endTime - * @property {string|null} [target] OperationMetadata target - * @property {string|null} [verb] OperationMetadata verb - * @property {string|null} [statusDetail] OperationMetadata statusDetail - * @property {boolean|null} [cancelRequested] OperationMetadata cancelRequested - * @property {string|null} [apiVersion] OperationMetadata apiVersion + * @interface ICreateConnectivityTestRequest + * @property {string|null} [parent] CreateConnectivityTestRequest parent + * @property {string|null} [testId] CreateConnectivityTestRequest testId + * @property {google.cloud.networkmanagement.v1.IConnectivityTest|null} [resource] CreateConnectivityTestRequest resource */ /** - * Constructs a new OperationMetadata. + * Constructs a new CreateConnectivityTestRequest. * @memberof google.cloud.networkmanagement.v1 - * @classdesc Represents an OperationMetadata. - * @implements IOperationMetadata + * @classdesc Represents a CreateConnectivityTestRequest. + * @implements ICreateConnectivityTestRequest * @constructor - * @param {google.cloud.networkmanagement.v1.IOperationMetadata=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest=} [properties] Properties to set */ - function OperationMetadata(properties) { + function CreateConnectivityTestRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -17017,159 +17674,103 @@ } /** - * OperationMetadata createTime. - * @member {google.protobuf.ITimestamp|null|undefined} createTime - * @memberof google.cloud.networkmanagement.v1.OperationMetadata - * @instance - */ - OperationMetadata.prototype.createTime = null; - - /** - * OperationMetadata endTime. - * @member {google.protobuf.ITimestamp|null|undefined} endTime - * @memberof google.cloud.networkmanagement.v1.OperationMetadata - * @instance - */ - OperationMetadata.prototype.endTime = null; - - /** - * OperationMetadata target. - * @member {string} target - * @memberof google.cloud.networkmanagement.v1.OperationMetadata - * @instance - */ - OperationMetadata.prototype.target = ""; - - /** - * OperationMetadata verb. - * @member {string} verb - * @memberof google.cloud.networkmanagement.v1.OperationMetadata - * @instance - */ - OperationMetadata.prototype.verb = ""; - - /** - * OperationMetadata statusDetail. - * @member {string} statusDetail - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * CreateConnectivityTestRequest parent. + * @member {string} parent + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @instance */ - OperationMetadata.prototype.statusDetail = ""; + CreateConnectivityTestRequest.prototype.parent = ""; /** - * OperationMetadata cancelRequested. - * @member {boolean} cancelRequested - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * CreateConnectivityTestRequest testId. + * @member {string} testId + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @instance */ - OperationMetadata.prototype.cancelRequested = false; + CreateConnectivityTestRequest.prototype.testId = ""; /** - * OperationMetadata apiVersion. - * @member {string} apiVersion - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * CreateConnectivityTestRequest resource. + * @member {google.cloud.networkmanagement.v1.IConnectivityTest|null|undefined} resource + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @instance */ - OperationMetadata.prototype.apiVersion = ""; + CreateConnectivityTestRequest.prototype.resource = null; /** - * Creates a new OperationMetadata instance using the specified properties. + * Creates a new CreateConnectivityTestRequest instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IOperationMetadata=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata instance + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest instance */ - OperationMetadata.create = function create(properties) { - return new OperationMetadata(properties); + CreateConnectivityTestRequest.create = function create(properties) { + return new CreateConnectivityTestRequest(properties); }; /** - * Encodes the specified OperationMetadata message. Does not implicitly {@link google.cloud.networkmanagement.v1.OperationMetadata.verify|verify} messages. + * Encodes the specified CreateConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IOperationMetadata} message OperationMetadata message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} message CreateConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OperationMetadata.encode = function encode(message, writer) { + CreateConnectivityTestRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) - $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.endTime != null && Object.hasOwnProperty.call(message, "endTime")) - $root.google.protobuf.Timestamp.encode(message.endTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.target != null && Object.hasOwnProperty.call(message, "target")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.target); - if (message.verb != null && Object.hasOwnProperty.call(message, "verb")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.verb); - if (message.statusDetail != null && Object.hasOwnProperty.call(message, "statusDetail")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.statusDetail); - if (message.cancelRequested != null && Object.hasOwnProperty.call(message, "cancelRequested")) - writer.uint32(/* id 6, wireType 0 =*/48).bool(message.cancelRequested); - if (message.apiVersion != null && Object.hasOwnProperty.call(message, "apiVersion")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.apiVersion); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.testId != null && Object.hasOwnProperty.call(message, "testId")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.testId); + if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) + $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resource, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified OperationMetadata message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.OperationMetadata.verify|verify} messages. + * Encodes the specified CreateConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.IOperationMetadata} message OperationMetadata message or plain object to encode + * @param {google.cloud.networkmanagement.v1.ICreateConnectivityTestRequest} message CreateConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OperationMetadata.encodeDelimited = function encodeDelimited(message, writer) { + CreateConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an OperationMetadata message from the specified reader or buffer. + * Decodes a CreateConnectivityTestRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata + * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OperationMetadata.decode = function decode(reader, length) { + CreateConnectivityTestRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.OperationMetadata(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.parent = reader.string(); break; } case 2: { - message.endTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.testId = reader.string(); break; } case 3: { - message.target = reader.string(); - break; - } - case 4: { - message.verb = reader.string(); - break; - } - case 5: { - message.statusDetail = reader.string(); - break; - } - case 6: { - message.cancelRequested = reader.bool(); - break; - } - case 7: { - message.apiVersion = reader.string(); + message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32()); break; } default: @@ -17181,207 +17782,145 @@ }; /** - * Decodes an OperationMetadata message from the specified reader or buffer, length delimited. + * Decodes a CreateConnectivityTestRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata + * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OperationMetadata.decodeDelimited = function decodeDelimited(reader) { + CreateConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an OperationMetadata message. + * Verifies a CreateConnectivityTestRequest message. * @function verify - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - OperationMetadata.verify = function verify(message) { + CreateConnectivityTestRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.createTime != null && message.hasOwnProperty("createTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.createTime); - if (error) - return "createTime." + error; - } - if (message.endTime != null && message.hasOwnProperty("endTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.endTime); + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.testId != null && message.hasOwnProperty("testId")) + if (!$util.isString(message.testId)) + return "testId: string expected"; + if (message.resource != null && message.hasOwnProperty("resource")) { + var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resource); if (error) - return "endTime." + error; + return "resource." + error; } - if (message.target != null && message.hasOwnProperty("target")) - if (!$util.isString(message.target)) - return "target: string expected"; - if (message.verb != null && message.hasOwnProperty("verb")) - if (!$util.isString(message.verb)) - return "verb: string expected"; - if (message.statusDetail != null && message.hasOwnProperty("statusDetail")) - if (!$util.isString(message.statusDetail)) - return "statusDetail: string expected"; - if (message.cancelRequested != null && message.hasOwnProperty("cancelRequested")) - if (typeof message.cancelRequested !== "boolean") - return "cancelRequested: boolean expected"; - if (message.apiVersion != null && message.hasOwnProperty("apiVersion")) - if (!$util.isString(message.apiVersion)) - return "apiVersion: string expected"; return null; }; /** - * Creates an OperationMetadata message from a plain object. Also converts values to their respective internal types. + * Creates a CreateConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata + * @returns {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} CreateConnectivityTestRequest */ - OperationMetadata.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1.OperationMetadata) + CreateConnectivityTestRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest) return object; - var message = new $root.google.cloud.networkmanagement.v1.OperationMetadata(); - if (object.createTime != null) { - if (typeof object.createTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.OperationMetadata.createTime: object expected"); - message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); - } - if (object.endTime != null) { - if (typeof object.endTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1.OperationMetadata.endTime: object expected"); - message.endTime = $root.google.protobuf.Timestamp.fromObject(object.endTime); + var message = new $root.google.cloud.networkmanagement.v1.CreateConnectivityTestRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.testId != null) + message.testId = String(object.testId); + if (object.resource != null) { + if (typeof object.resource !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.CreateConnectivityTestRequest.resource: object expected"); + message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resource); } - if (object.target != null) - message.target = String(object.target); - if (object.verb != null) - message.verb = String(object.verb); - if (object.statusDetail != null) - message.statusDetail = String(object.statusDetail); - if (object.cancelRequested != null) - message.cancelRequested = Boolean(object.cancelRequested); - if (object.apiVersion != null) - message.apiVersion = String(object.apiVersion); return message; }; /** - * Creates a plain object from an OperationMetadata message. Also converts values to other types if specified. + * Creates a plain object from a CreateConnectivityTestRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1.OperationMetadata} message OperationMetadata + * @param {google.cloud.networkmanagement.v1.CreateConnectivityTestRequest} message CreateConnectivityTestRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - OperationMetadata.toObject = function toObject(message, options) { + CreateConnectivityTestRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.createTime = null; - object.endTime = null; - object.target = ""; - object.verb = ""; - object.statusDetail = ""; - object.cancelRequested = false; - object.apiVersion = ""; + object.parent = ""; + object.testId = ""; + object.resource = null; } - if (message.createTime != null && message.hasOwnProperty("createTime")) - object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); - if (message.endTime != null && message.hasOwnProperty("endTime")) - object.endTime = $root.google.protobuf.Timestamp.toObject(message.endTime, options); - if (message.target != null && message.hasOwnProperty("target")) - object.target = message.target; - if (message.verb != null && message.hasOwnProperty("verb")) - object.verb = message.verb; - if (message.statusDetail != null && message.hasOwnProperty("statusDetail")) - object.statusDetail = message.statusDetail; - if (message.cancelRequested != null && message.hasOwnProperty("cancelRequested")) - object.cancelRequested = message.cancelRequested; - if (message.apiVersion != null && message.hasOwnProperty("apiVersion")) - object.apiVersion = message.apiVersion; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.testId != null && message.hasOwnProperty("testId")) + object.testId = message.testId; + if (message.resource != null && message.hasOwnProperty("resource")) + object.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resource, options); return object; }; /** - * Converts this OperationMetadata to JSON. + * Converts this CreateConnectivityTestRequest to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @instance * @returns {Object.} JSON object */ - OperationMetadata.prototype.toJSON = function toJSON() { + CreateConnectivityTestRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for OperationMetadata + * Gets the default type url for CreateConnectivityTestRequest * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @memberof google.cloud.networkmanagement.v1.CreateConnectivityTestRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - OperationMetadata.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1.OperationMetadata"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.CreateConnectivityTestRequest"; }; - return OperationMetadata; + return CreateConnectivityTestRequest; })(); - return v1; - })(); - - networkmanagement.v1beta1 = (function() { - - /** - * Namespace v1beta1. - * @memberof google.cloud.networkmanagement - * @namespace - */ - var v1beta1 = {}; - - v1beta1.ConnectivityTest = (function() { + v1.UpdateConnectivityTestRequest = (function() { /** - * Properties of a ConnectivityTest. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IConnectivityTest - * @property {string|null} [name] ConnectivityTest name - * @property {string|null} [description] ConnectivityTest description - * @property {google.cloud.networkmanagement.v1beta1.IEndpoint|null} [source] ConnectivityTest source - * @property {google.cloud.networkmanagement.v1beta1.IEndpoint|null} [destination] ConnectivityTest destination - * @property {string|null} [protocol] ConnectivityTest protocol - * @property {Array.|null} [relatedProjects] ConnectivityTest relatedProjects - * @property {string|null} [displayName] ConnectivityTest displayName - * @property {Object.|null} [labels] ConnectivityTest labels - * @property {google.protobuf.ITimestamp|null} [createTime] ConnectivityTest createTime - * @property {google.protobuf.ITimestamp|null} [updateTime] ConnectivityTest updateTime - * @property {google.cloud.networkmanagement.v1beta1.IReachabilityDetails|null} [reachabilityDetails] ConnectivityTest reachabilityDetails - * @property {google.cloud.networkmanagement.v1beta1.IProbingDetails|null} [probingDetails] ConnectivityTest probingDetails - * @property {boolean|null} [bypassFirewallChecks] ConnectivityTest bypassFirewallChecks + * Properties of an UpdateConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @interface IUpdateConnectivityTestRequest + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateConnectivityTestRequest updateMask + * @property {google.cloud.networkmanagement.v1.IConnectivityTest|null} [resource] UpdateConnectivityTestRequest resource */ /** - * Constructs a new ConnectivityTest. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a ConnectivityTest. - * @implements IConnectivityTest + * Constructs a new UpdateConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents an UpdateConnectivityTestRequest. + * @implements IUpdateConnectivityTestRequest * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest=} [properties] Properties to set */ - function ConnectivityTest(properties) { - this.relatedProjects = []; - this.labels = {}; + function UpdateConnectivityTestRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -17389,192 +17928,306 @@ } /** - * ConnectivityTest name. - * @member {string} name - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * UpdateConnectivityTestRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest * @instance */ - ConnectivityTest.prototype.name = ""; + UpdateConnectivityTestRequest.prototype.updateMask = null; /** - * ConnectivityTest description. - * @member {string} description - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * UpdateConnectivityTestRequest resource. + * @member {google.cloud.networkmanagement.v1.IConnectivityTest|null|undefined} resource + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest * @instance */ - ConnectivityTest.prototype.description = ""; + UpdateConnectivityTestRequest.prototype.resource = null; /** - * ConnectivityTest source. - * @member {google.cloud.networkmanagement.v1beta1.IEndpoint|null|undefined} source - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Creates a new UpdateConnectivityTestRequest instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest instance */ - ConnectivityTest.prototype.source = null; + UpdateConnectivityTestRequest.create = function create(properties) { + return new UpdateConnectivityTestRequest(properties); + }; /** - * ConnectivityTest destination. - * @member {google.cloud.networkmanagement.v1beta1.IEndpoint|null|undefined} destination - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Encodes the specified UpdateConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} message UpdateConnectivityTestRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - ConnectivityTest.prototype.destination = null; + UpdateConnectivityTestRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) + $root.google.cloud.networkmanagement.v1.ConnectivityTest.encode(message.resource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; /** - * ConnectivityTest protocol. - * @member {string} protocol - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Encodes the specified UpdateConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IUpdateConnectivityTestRequest} message UpdateConnectivityTestRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - ConnectivityTest.prototype.protocol = ""; + UpdateConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * ConnectivityTest relatedProjects. - * @member {Array.} relatedProjects - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Decodes an UpdateConnectivityTestRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ConnectivityTest.prototype.relatedProjects = $util.emptyArray; + UpdateConnectivityTestRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + break; + } + case 2: { + message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * ConnectivityTest displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Decodes an UpdateConnectivityTestRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ConnectivityTest.prototype.displayName = ""; + UpdateConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * ConnectivityTest labels. - * @member {Object.} labels - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance - */ - ConnectivityTest.prototype.labels = $util.emptyObject; + * Verifies an UpdateConnectivityTestRequest message. + * @function verify + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + UpdateConnectivityTestRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; + } + if (message.resource != null && message.hasOwnProperty("resource")) { + var error = $root.google.cloud.networkmanagement.v1.ConnectivityTest.verify(message.resource); + if (error) + return "resource." + error; + } + return null; + }; /** - * ConnectivityTest createTime. - * @member {google.protobuf.ITimestamp|null|undefined} createTime - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Creates an UpdateConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} UpdateConnectivityTestRequest */ - ConnectivityTest.prototype.createTime = null; + UpdateConnectivityTestRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest) + return object; + var message = new $root.google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest(); + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + } + if (object.resource != null) { + if (typeof object.resource !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest.resource: object expected"); + message.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.fromObject(object.resource); + } + return message; + }; /** - * ConnectivityTest updateTime. - * @member {google.protobuf.ITimestamp|null|undefined} updateTime - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Creates a plain object from an UpdateConnectivityTestRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest} message UpdateConnectivityTestRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - ConnectivityTest.prototype.updateTime = null; + UpdateConnectivityTestRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.updateMask = null; + object.resource = null; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + if (message.resource != null && message.hasOwnProperty("resource")) + object.resource = $root.google.cloud.networkmanagement.v1.ConnectivityTest.toObject(message.resource, options); + return object; + }; /** - * ConnectivityTest reachabilityDetails. - * @member {google.cloud.networkmanagement.v1beta1.IReachabilityDetails|null|undefined} reachabilityDetails - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * Converts this UpdateConnectivityTestRequest to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest * @instance + * @returns {Object.} JSON object */ - ConnectivityTest.prototype.reachabilityDetails = null; + UpdateConnectivityTestRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * ConnectivityTest probingDetails. - * @member {google.cloud.networkmanagement.v1beta1.IProbingDetails|null|undefined} probingDetails - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest - * @instance + * Gets the default type url for UpdateConnectivityTestRequest + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ - ConnectivityTest.prototype.probingDetails = null; + UpdateConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.UpdateConnectivityTestRequest"; + }; + + return UpdateConnectivityTestRequest; + })(); + + v1.DeleteConnectivityTestRequest = (function() { /** - * ConnectivityTest bypassFirewallChecks. - * @member {boolean} bypassFirewallChecks - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * Properties of a DeleteConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @interface IDeleteConnectivityTestRequest + * @property {string|null} [name] DeleteConnectivityTestRequest name + */ + + /** + * Constructs a new DeleteConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents a DeleteConnectivityTestRequest. + * @implements IDeleteConnectivityTestRequest + * @constructor + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest=} [properties] Properties to set + */ + function DeleteConnectivityTestRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * DeleteConnectivityTestRequest name. + * @member {string} name + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @instance */ - ConnectivityTest.prototype.bypassFirewallChecks = false; + DeleteConnectivityTestRequest.prototype.name = ""; /** - * Creates a new ConnectivityTest instance using the specified properties. + * Creates a new DeleteConnectivityTestRequest instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest instance + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest instance */ - ConnectivityTest.create = function create(properties) { - return new ConnectivityTest(properties); + DeleteConnectivityTestRequest.create = function create(properties) { + return new DeleteConnectivityTestRequest(properties); }; /** - * Encodes the specified ConnectivityTest message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ConnectivityTest.verify|verify} messages. + * Encodes the specified DeleteConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest} message ConnectivityTest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} message DeleteConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ConnectivityTest.encode = function encode(message, writer) { + DeleteConnectivityTestRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); - if (message.source != null && Object.hasOwnProperty.call(message, "source")) - $root.google.cloud.networkmanagement.v1beta1.Endpoint.encode(message.source, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.destination != null && Object.hasOwnProperty.call(message, "destination")) - $root.google.cloud.networkmanagement.v1beta1.Endpoint.encode(message.destination, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.protocol); - if (message.relatedProjects != null && message.relatedProjects.length) - for (var i = 0; i < message.relatedProjects.length; ++i) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.relatedProjects[i]); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.displayName); - if (message.labels != null && Object.hasOwnProperty.call(message, "labels")) - for (var keys = Object.keys(message.labels), i = 0; i < keys.length; ++i) - writer.uint32(/* id 8, wireType 2 =*/66).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.labels[keys[i]]).ldelim(); - if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) - $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); - if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) - $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); - if (message.reachabilityDetails != null && Object.hasOwnProperty.call(message, "reachabilityDetails")) - $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.encode(message.reachabilityDetails, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); - if (message.probingDetails != null && Object.hasOwnProperty.call(message, "probingDetails")) - $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.encode(message.probingDetails, writer.uint32(/* id 14, wireType 2 =*/114).fork()).ldelim(); - if (message.bypassFirewallChecks != null && Object.hasOwnProperty.call(message, "bypassFirewallChecks")) - writer.uint32(/* id 17, wireType 0 =*/136).bool(message.bypassFirewallChecks); return writer; }; /** - * Encodes the specified ConnectivityTest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ConnectivityTest.verify|verify} messages. + * Encodes the specified DeleteConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest} message ConnectivityTest message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IDeleteConnectivityTestRequest} message DeleteConnectivityTestRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ConnectivityTest.encodeDelimited = function encodeDelimited(message, writer) { + DeleteConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ConnectivityTest message from the specified reader or buffer. + * Decodes a DeleteConnectivityTestRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ConnectivityTest.decode = function decode(reader, length) { + DeleteConnectivityTestRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -17582,75 +18235,6 @@ message.name = reader.string(); break; } - case 2: { - message.description = reader.string(); - break; - } - case 3: { - message.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.decode(reader, reader.uint32()); - break; - } - case 4: { - message.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.decode(reader, reader.uint32()); - break; - } - case 5: { - message.protocol = reader.string(); - break; - } - case 6: { - if (!(message.relatedProjects && message.relatedProjects.length)) - message.relatedProjects = []; - message.relatedProjects.push(reader.string()); - break; - } - case 7: { - message.displayName = reader.string(); - break; - } - case 8: { - if (message.labels === $util.emptyObject) - message.labels = {}; - var end2 = reader.uint32() + reader.pos; - key = ""; - value = ""; - while (reader.pos < end2) { - var tag2 = reader.uint32(); - switch (tag2 >>> 3) { - case 1: - key = reader.string(); - break; - case 2: - value = reader.string(); - break; - default: - reader.skipType(tag2 & 7); - break; - } - } - message.labels[key] = value; - break; - } - case 10: { - message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 11: { - message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 12: { - message.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.decode(reader, reader.uint32()); - break; - } - case 14: { - message.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.decode(reader, reader.uint32()); - break; - } - case 17: { - message.bypassFirewallChecks = reader.bool(); - break; - } default: reader.skipType(tag & 7); break; @@ -17660,291 +18244,122 @@ }; /** - * Decodes a ConnectivityTest message from the specified reader or buffer, length delimited. + * Decodes a DeleteConnectivityTestRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ConnectivityTest.decodeDelimited = function decodeDelimited(reader) { + DeleteConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ConnectivityTest message. + * Verifies a DeleteConnectivityTestRequest message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ConnectivityTest.verify = function verify(message) { + DeleteConnectivityTestRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.source != null && message.hasOwnProperty("source")) { - var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.verify(message.source); - if (error) - return "source." + error; - } - if (message.destination != null && message.hasOwnProperty("destination")) { - var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.verify(message.destination); - if (error) - return "destination." + error; - } - if (message.protocol != null && message.hasOwnProperty("protocol")) - if (!$util.isString(message.protocol)) - return "protocol: string expected"; - if (message.relatedProjects != null && message.hasOwnProperty("relatedProjects")) { - if (!Array.isArray(message.relatedProjects)) - return "relatedProjects: array expected"; - for (var i = 0; i < message.relatedProjects.length; ++i) - if (!$util.isString(message.relatedProjects[i])) - return "relatedProjects: string[] expected"; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.labels != null && message.hasOwnProperty("labels")) { - if (!$util.isObject(message.labels)) - return "labels: object expected"; - var key = Object.keys(message.labels); - for (var i = 0; i < key.length; ++i) - if (!$util.isString(message.labels[key[i]])) - return "labels: string{k:string} expected"; - } - if (message.createTime != null && message.hasOwnProperty("createTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.createTime); - if (error) - return "createTime." + error; - } - if (message.updateTime != null && message.hasOwnProperty("updateTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.updateTime); - if (error) - return "updateTime." + error; - } - if (message.reachabilityDetails != null && message.hasOwnProperty("reachabilityDetails")) { - var error = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify(message.reachabilityDetails); - if (error) - return "reachabilityDetails." + error; - } - if (message.probingDetails != null && message.hasOwnProperty("probingDetails")) { - var error = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.verify(message.probingDetails); - if (error) - return "probingDetails." + error; - } - if (message.bypassFirewallChecks != null && message.hasOwnProperty("bypassFirewallChecks")) - if (typeof message.bypassFirewallChecks !== "boolean") - return "bypassFirewallChecks: boolean expected"; return null; }; /** - * Creates a ConnectivityTest message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + * @returns {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} DeleteConnectivityTestRequest */ - ConnectivityTest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest) + DeleteConnectivityTestRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest(); + var message = new $root.google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest(); if (object.name != null) message.name = String(object.name); - if (object.description != null) - message.description = String(object.description); - if (object.source != null) { - if (typeof object.source !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.source: object expected"); - message.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.fromObject(object.source); - } - if (object.destination != null) { - if (typeof object.destination !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.destination: object expected"); - message.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.fromObject(object.destination); - } - if (object.protocol != null) - message.protocol = String(object.protocol); - if (object.relatedProjects) { - if (!Array.isArray(object.relatedProjects)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.relatedProjects: array expected"); - message.relatedProjects = []; - for (var i = 0; i < object.relatedProjects.length; ++i) - message.relatedProjects[i] = String(object.relatedProjects[i]); - } - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.labels) { - if (typeof object.labels !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.labels: object expected"); - message.labels = {}; - for (var keys = Object.keys(object.labels), i = 0; i < keys.length; ++i) - message.labels[keys[i]] = String(object.labels[keys[i]]); - } - if (object.createTime != null) { - if (typeof object.createTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.createTime: object expected"); - message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); - } - if (object.updateTime != null) { - if (typeof object.updateTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.updateTime: object expected"); - message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); - } - if (object.reachabilityDetails != null) { - if (typeof object.reachabilityDetails !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.reachabilityDetails: object expected"); - message.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.fromObject(object.reachabilityDetails); - } - if (object.probingDetails != null) { - if (typeof object.probingDetails !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.probingDetails: object expected"); - message.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.fromObject(object.probingDetails); - } - if (object.bypassFirewallChecks != null) - message.bypassFirewallChecks = Boolean(object.bypassFirewallChecks); return message; }; /** - * Creates a plain object from a ConnectivityTest message. Also converts values to other types if specified. + * Creates a plain object from a DeleteConnectivityTestRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static - * @param {google.cloud.networkmanagement.v1beta1.ConnectivityTest} message ConnectivityTest + * @param {google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest} message DeleteConnectivityTestRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ConnectivityTest.toObject = function toObject(message, options) { + DeleteConnectivityTestRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.relatedProjects = []; - if (options.objects || options.defaults) - object.labels = {}; - if (options.defaults) { + if (options.defaults) object.name = ""; - object.description = ""; - object.source = null; - object.destination = null; - object.protocol = ""; - object.displayName = ""; - object.createTime = null; - object.updateTime = null; - object.reachabilityDetails = null; - object.probingDetails = null; - object.bypassFirewallChecks = false; - } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.source != null && message.hasOwnProperty("source")) - object.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.toObject(message.source, options); - if (message.destination != null && message.hasOwnProperty("destination")) - object.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.toObject(message.destination, options); - if (message.protocol != null && message.hasOwnProperty("protocol")) - object.protocol = message.protocol; - if (message.relatedProjects && message.relatedProjects.length) { - object.relatedProjects = []; - for (var j = 0; j < message.relatedProjects.length; ++j) - object.relatedProjects[j] = message.relatedProjects[j]; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - var keys2; - if (message.labels && (keys2 = Object.keys(message.labels)).length) { - object.labels = {}; - for (var j = 0; j < keys2.length; ++j) - object.labels[keys2[j]] = message.labels[keys2[j]]; - } - if (message.createTime != null && message.hasOwnProperty("createTime")) - object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); - if (message.updateTime != null && message.hasOwnProperty("updateTime")) - object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); - if (message.reachabilityDetails != null && message.hasOwnProperty("reachabilityDetails")) - object.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.toObject(message.reachabilityDetails, options); - if (message.probingDetails != null && message.hasOwnProperty("probingDetails")) - object.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.toObject(message.probingDetails, options); - if (message.bypassFirewallChecks != null && message.hasOwnProperty("bypassFirewallChecks")) - object.bypassFirewallChecks = message.bypassFirewallChecks; return object; }; /** - * Converts this ConnectivityTest to JSON. + * Converts this DeleteConnectivityTestRequest to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @instance * @returns {Object.} JSON object */ - ConnectivityTest.prototype.toJSON = function toJSON() { + DeleteConnectivityTestRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ConnectivityTest + * Gets the default type url for DeleteConnectivityTestRequest * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @memberof google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ConnectivityTest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ConnectivityTest"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.DeleteConnectivityTestRequest"; }; - return ConnectivityTest; + return DeleteConnectivityTestRequest; })(); - v1beta1.Endpoint = (function() { + v1.RerunConnectivityTestRequest = (function() { /** - * Properties of an Endpoint. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IEndpoint - * @property {string|null} [ipAddress] Endpoint ipAddress - * @property {number|null} [port] Endpoint port - * @property {string|null} [instance] Endpoint instance - * @property {string|null} [forwardingRule] Endpoint forwardingRule - * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget|null} [forwardingRuleTarget] Endpoint forwardingRuleTarget - * @property {string|null} [loadBalancerId] Endpoint loadBalancerId - * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerType|null} [loadBalancerType] Endpoint loadBalancerType - * @property {string|null} [gkeMasterCluster] Endpoint gkeMasterCluster - * @property {string|null} [cloudSqlInstance] Endpoint cloudSqlInstance - * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null} [cloudFunction] Endpoint cloudFunction - * @property {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint|null} [appEngineVersion] Endpoint appEngineVersion - * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint|null} [cloudRunRevision] Endpoint cloudRunRevision - * @property {string|null} [network] Endpoint network - * @property {google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType|null} [networkType] Endpoint networkType - * @property {string|null} [projectId] Endpoint projectId + * Properties of a RerunConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @interface IRerunConnectivityTestRequest + * @property {string|null} [name] RerunConnectivityTestRequest name */ /** - * Constructs a new Endpoint. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents an Endpoint. - * @implements IEndpoint + * Constructs a new RerunConnectivityTestRequest. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents a RerunConnectivityTestRequest. + * @implements IRerunConnectivityTestRequest * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IEndpoint=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest=} [properties] Properties to set */ - function Endpoint(properties) { + function RerunConnectivityTestRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -17952,307 +18367,368 @@ } /** - * Endpoint ipAddress. - * @member {string} ipAddress - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * RerunConnectivityTestRequest name. + * @member {string} name + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest * @instance */ - Endpoint.prototype.ipAddress = ""; + RerunConnectivityTestRequest.prototype.name = ""; /** - * Endpoint port. - * @member {number} port - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Creates a new RerunConnectivityTestRequest instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest instance */ - Endpoint.prototype.port = 0; + RerunConnectivityTestRequest.create = function create(properties) { + return new RerunConnectivityTestRequest(properties); + }; /** - * Endpoint instance. - * @member {string} instance - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Encodes the specified RerunConnectivityTestRequest message. Does not implicitly {@link google.cloud.networkmanagement.v1.RerunConnectivityTestRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} message RerunConnectivityTestRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Endpoint.prototype.instance = ""; + RerunConnectivityTestRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; /** - * Endpoint forwardingRule. - * @member {string} forwardingRule - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Encodes the specified RerunConnectivityTestRequest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.RerunConnectivityTestRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.IRerunConnectivityTestRequest} message RerunConnectivityTestRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Endpoint.prototype.forwardingRule = ""; + RerunConnectivityTestRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Endpoint forwardingRuleTarget. - * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget|null|undefined} forwardingRuleTarget - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Decodes a RerunConnectivityTestRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Endpoint.prototype.forwardingRuleTarget = null; + RerunConnectivityTestRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Endpoint loadBalancerId. - * @member {string|null|undefined} loadBalancerId - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Decodes a RerunConnectivityTestRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Endpoint.prototype.loadBalancerId = null; + RerunConnectivityTestRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Endpoint loadBalancerType. - * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerType|null|undefined} loadBalancerType - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Verifies a RerunConnectivityTestRequest message. + * @function verify + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Endpoint.prototype.loadBalancerType = null; + RerunConnectivityTestRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; /** - * Endpoint gkeMasterCluster. - * @member {string} gkeMasterCluster - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Creates a RerunConnectivityTestRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} RerunConnectivityTestRequest */ - Endpoint.prototype.gkeMasterCluster = ""; + RerunConnectivityTestRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest) + return object; + var message = new $root.google.cloud.networkmanagement.v1.RerunConnectivityTestRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; /** - * Endpoint cloudSqlInstance. - * @member {string} cloudSqlInstance - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Creates a plain object from a RerunConnectivityTestRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {google.cloud.networkmanagement.v1.RerunConnectivityTestRequest} message RerunConnectivityTestRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - Endpoint.prototype.cloudSqlInstance = ""; + RerunConnectivityTestRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; /** - * Endpoint cloudFunction. - * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null|undefined} cloudFunction - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * Converts this RerunConnectivityTestRequest to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest * @instance + * @returns {Object.} JSON object */ - Endpoint.prototype.cloudFunction = null; + RerunConnectivityTestRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Endpoint appEngineVersion. - * @member {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint|null|undefined} appEngineVersion - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Gets the default type url for RerunConnectivityTestRequest + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1.RerunConnectivityTestRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ - Endpoint.prototype.appEngineVersion = null; + RerunConnectivityTestRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.RerunConnectivityTestRequest"; + }; + + return RerunConnectivityTestRequest; + })(); + + v1.OperationMetadata = (function() { /** - * Endpoint cloudRunRevision. - * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint|null|undefined} cloudRunRevision - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Properties of an OperationMetadata. + * @memberof google.cloud.networkmanagement.v1 + * @interface IOperationMetadata + * @property {google.protobuf.ITimestamp|null} [createTime] OperationMetadata createTime + * @property {google.protobuf.ITimestamp|null} [endTime] OperationMetadata endTime + * @property {string|null} [target] OperationMetadata target + * @property {string|null} [verb] OperationMetadata verb + * @property {string|null} [statusDetail] OperationMetadata statusDetail + * @property {boolean|null} [cancelRequested] OperationMetadata cancelRequested + * @property {string|null} [apiVersion] OperationMetadata apiVersion */ - Endpoint.prototype.cloudRunRevision = null; /** - * Endpoint network. - * @member {string} network - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * Constructs a new OperationMetadata. + * @memberof google.cloud.networkmanagement.v1 + * @classdesc Represents an OperationMetadata. + * @implements IOperationMetadata + * @constructor + * @param {google.cloud.networkmanagement.v1.IOperationMetadata=} [properties] Properties to set */ - Endpoint.prototype.network = ""; + function OperationMetadata(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Endpoint networkType. - * @member {google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType} networkType - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * OperationMetadata createTime. + * @member {google.protobuf.ITimestamp|null|undefined} createTime + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @instance */ - Endpoint.prototype.networkType = 0; + OperationMetadata.prototype.createTime = null; /** - * Endpoint projectId. - * @member {string} projectId - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * OperationMetadata endTime. + * @member {google.protobuf.ITimestamp|null|undefined} endTime + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @instance */ - Endpoint.prototype.projectId = ""; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + OperationMetadata.prototype.endTime = null; /** - * Endpoint _forwardingRuleTarget. - * @member {"forwardingRuleTarget"|undefined} _forwardingRuleTarget - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @instance + * OperationMetadata target. + * @member {string} target + * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @instance */ - Object.defineProperty(Endpoint.prototype, "_forwardingRuleTarget", { - get: $util.oneOfGetter($oneOfFields = ["forwardingRuleTarget"]), - set: $util.oneOfSetter($oneOfFields) - }); + OperationMetadata.prototype.target = ""; /** - * Endpoint _loadBalancerId. - * @member {"loadBalancerId"|undefined} _loadBalancerId - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * OperationMetadata verb. + * @member {string} verb + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @instance */ - Object.defineProperty(Endpoint.prototype, "_loadBalancerId", { - get: $util.oneOfGetter($oneOfFields = ["loadBalancerId"]), - set: $util.oneOfSetter($oneOfFields) - }); + OperationMetadata.prototype.verb = ""; /** - * Endpoint _loadBalancerType. - * @member {"loadBalancerType"|undefined} _loadBalancerType - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * OperationMetadata statusDetail. + * @member {string} statusDetail + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @instance */ - Object.defineProperty(Endpoint.prototype, "_loadBalancerType", { - get: $util.oneOfGetter($oneOfFields = ["loadBalancerType"]), - set: $util.oneOfSetter($oneOfFields) - }); + OperationMetadata.prototype.statusDetail = ""; /** - * Creates a new Endpoint instance using the specified properties. + * OperationMetadata cancelRequested. + * @member {boolean} cancelRequested + * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @instance + */ + OperationMetadata.prototype.cancelRequested = false; + + /** + * OperationMetadata apiVersion. + * @member {string} apiVersion + * @memberof google.cloud.networkmanagement.v1.OperationMetadata + * @instance + */ + OperationMetadata.prototype.apiVersion = ""; + + /** + * Creates a new OperationMetadata instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpoint=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint instance + * @param {google.cloud.networkmanagement.v1.IOperationMetadata=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata instance */ - Endpoint.create = function create(properties) { - return new Endpoint(properties); + OperationMetadata.create = function create(properties) { + return new OperationMetadata(properties); }; /** - * Encodes the specified Endpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.verify|verify} messages. + * Encodes the specified OperationMetadata message. Does not implicitly {@link google.cloud.networkmanagement.v1.OperationMetadata.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpoint} message Endpoint message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IOperationMetadata} message OperationMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Endpoint.encode = function encode(message, writer) { + OperationMetadata.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.ipAddress); - if (message.port != null && Object.hasOwnProperty.call(message, "port")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.port); - if (message.instance != null && Object.hasOwnProperty.call(message, "instance")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.instance); - if (message.network != null && Object.hasOwnProperty.call(message, "network")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.network); - if (message.networkType != null && Object.hasOwnProperty.call(message, "networkType")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.networkType); - if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.projectId); - if (message.gkeMasterCluster != null && Object.hasOwnProperty.call(message, "gkeMasterCluster")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.gkeMasterCluster); - if (message.cloudSqlInstance != null && Object.hasOwnProperty.call(message, "cloudSqlInstance")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.cloudSqlInstance); - if (message.cloudFunction != null && Object.hasOwnProperty.call(message, "cloudFunction")) - $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.encode(message.cloudFunction, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); - if (message.appEngineVersion != null && Object.hasOwnProperty.call(message, "appEngineVersion")) - $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.encode(message.appEngineVersion, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); - if (message.cloudRunRevision != null && Object.hasOwnProperty.call(message, "cloudRunRevision")) - $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.encode(message.cloudRunRevision, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); - if (message.forwardingRule != null && Object.hasOwnProperty.call(message, "forwardingRule")) - writer.uint32(/* id 13, wireType 2 =*/106).string(message.forwardingRule); - if (message.forwardingRuleTarget != null && Object.hasOwnProperty.call(message, "forwardingRuleTarget")) - writer.uint32(/* id 14, wireType 0 =*/112).int32(message.forwardingRuleTarget); - if (message.loadBalancerId != null && Object.hasOwnProperty.call(message, "loadBalancerId")) - writer.uint32(/* id 15, wireType 2 =*/122).string(message.loadBalancerId); - if (message.loadBalancerType != null && Object.hasOwnProperty.call(message, "loadBalancerType")) - writer.uint32(/* id 16, wireType 0 =*/128).int32(message.loadBalancerType); + if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) + $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.endTime != null && Object.hasOwnProperty.call(message, "endTime")) + $root.google.protobuf.Timestamp.encode(message.endTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.target != null && Object.hasOwnProperty.call(message, "target")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.target); + if (message.verb != null && Object.hasOwnProperty.call(message, "verb")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.verb); + if (message.statusDetail != null && Object.hasOwnProperty.call(message, "statusDetail")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.statusDetail); + if (message.cancelRequested != null && Object.hasOwnProperty.call(message, "cancelRequested")) + writer.uint32(/* id 6, wireType 0 =*/48).bool(message.cancelRequested); + if (message.apiVersion != null && Object.hasOwnProperty.call(message, "apiVersion")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.apiVersion); return writer; }; /** - * Encodes the specified Endpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.verify|verify} messages. + * Encodes the specified OperationMetadata message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1.OperationMetadata.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpoint} message Endpoint message or plain object to encode + * @param {google.cloud.networkmanagement.v1.IOperationMetadata} message OperationMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Endpoint.encodeDelimited = function encodeDelimited(message, writer) { + OperationMetadata.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an Endpoint message from the specified reader or buffer. + * Decodes an OperationMetadata message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint + * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Endpoint.decode = function decode(reader, length) { + OperationMetadata.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1.OperationMetadata(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.ipAddress = reader.string(); + message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); break; } case 2: { - message.port = reader.int32(); + message.endTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); break; } case 3: { - message.instance = reader.string(); - break; - } - case 13: { - message.forwardingRule = reader.string(); - break; - } - case 14: { - message.forwardingRuleTarget = reader.int32(); - break; - } - case 15: { - message.loadBalancerId = reader.string(); - break; - } - case 16: { - message.loadBalancerType = reader.int32(); - break; - } - case 7: { - message.gkeMasterCluster = reader.string(); - break; - } - case 8: { - message.cloudSqlInstance = reader.string(); - break; - } - case 10: { - message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.decode(reader, reader.uint32()); - break; - } - case 11: { - message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.decode(reader, reader.uint32()); - break; - } - case 12: { - message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.decode(reader, reader.uint32()); + message.target = reader.string(); break; } case 4: { - message.network = reader.string(); + message.verb = reader.string(); break; } case 5: { - message.networkType = reader.int32(); + message.statusDetail = reader.string(); break; } case 6: { - message.projectId = reader.string(); + message.cancelRequested = reader.bool(); + break; + } + case 7: { + message.apiVersion = reader.string(); break; } default: @@ -18264,1034 +18740,772 @@ }; /** - * Decodes an Endpoint message from the specified reader or buffer, length delimited. + * Decodes an OperationMetadata message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint + * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Endpoint.decodeDelimited = function decodeDelimited(reader) { + OperationMetadata.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an Endpoint message. + * Verifies an OperationMetadata message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Endpoint.verify = function verify(message) { + OperationMetadata.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - if (!$util.isString(message.ipAddress)) - return "ipAddress: string expected"; - if (message.port != null && message.hasOwnProperty("port")) - if (!$util.isInteger(message.port)) - return "port: integer expected"; - if (message.instance != null && message.hasOwnProperty("instance")) - if (!$util.isString(message.instance)) - return "instance: string expected"; - if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) - if (!$util.isString(message.forwardingRule)) - return "forwardingRule: string expected"; - if (message.forwardingRuleTarget != null && message.hasOwnProperty("forwardingRuleTarget")) { - properties._forwardingRuleTarget = 1; - switch (message.forwardingRuleTarget) { - default: - return "forwardingRuleTarget: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - break; - } - } - if (message.loadBalancerId != null && message.hasOwnProperty("loadBalancerId")) { - properties._loadBalancerId = 1; - if (!$util.isString(message.loadBalancerId)) - return "loadBalancerId: string expected"; + if (message.createTime != null && message.hasOwnProperty("createTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.createTime); + if (error) + return "createTime." + error; } - if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) { - properties._loadBalancerType = 1; - switch (message.loadBalancerType) { - default: - return "loadBalancerType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - case 10: - break; - } + if (message.endTime != null && message.hasOwnProperty("endTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.endTime); + if (error) + return "endTime." + error; } - if (message.gkeMasterCluster != null && message.hasOwnProperty("gkeMasterCluster")) - if (!$util.isString(message.gkeMasterCluster)) - return "gkeMasterCluster: string expected"; - if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) - if (!$util.isString(message.cloudSqlInstance)) - return "cloudSqlInstance: string expected"; - if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { - var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify(message.cloudFunction); - if (error) - return "cloudFunction." + error; - } - if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { - var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify(message.appEngineVersion); - if (error) - return "appEngineVersion." + error; - } - if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { - var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify(message.cloudRunRevision); - if (error) - return "cloudRunRevision." + error; - } - if (message.network != null && message.hasOwnProperty("network")) - if (!$util.isString(message.network)) - return "network: string expected"; - if (message.networkType != null && message.hasOwnProperty("networkType")) - switch (message.networkType) { - default: - return "networkType: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.projectId != null && message.hasOwnProperty("projectId")) - if (!$util.isString(message.projectId)) - return "projectId: string expected"; + if (message.target != null && message.hasOwnProperty("target")) + if (!$util.isString(message.target)) + return "target: string expected"; + if (message.verb != null && message.hasOwnProperty("verb")) + if (!$util.isString(message.verb)) + return "verb: string expected"; + if (message.statusDetail != null && message.hasOwnProperty("statusDetail")) + if (!$util.isString(message.statusDetail)) + return "statusDetail: string expected"; + if (message.cancelRequested != null && message.hasOwnProperty("cancelRequested")) + if (typeof message.cancelRequested !== "boolean") + return "cancelRequested: boolean expected"; + if (message.apiVersion != null && message.hasOwnProperty("apiVersion")) + if (!$util.isString(message.apiVersion)) + return "apiVersion: string expected"; return null; }; /** - * Creates an Endpoint message from a plain object. Also converts values to their respective internal types. + * Creates an OperationMetadata message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint + * @returns {google.cloud.networkmanagement.v1.OperationMetadata} OperationMetadata */ - Endpoint.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint) + OperationMetadata.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1.OperationMetadata) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint(); - if (object.ipAddress != null) - message.ipAddress = String(object.ipAddress); - if (object.port != null) - message.port = object.port | 0; - if (object.instance != null) - message.instance = String(object.instance); - if (object.forwardingRule != null) - message.forwardingRule = String(object.forwardingRule); - switch (object.forwardingRuleTarget) { - default: - if (typeof object.forwardingRuleTarget === "number") { - message.forwardingRuleTarget = object.forwardingRuleTarget; - break; - } - break; - case "FORWARDING_RULE_TARGET_UNSPECIFIED": - case 0: - message.forwardingRuleTarget = 0; - break; - case "INSTANCE": - case 1: - message.forwardingRuleTarget = 1; - break; - case "LOAD_BALANCER": - case 2: - message.forwardingRuleTarget = 2; - break; - case "VPN_GATEWAY": - case 3: - message.forwardingRuleTarget = 3; - break; - case "PSC": - case 4: - message.forwardingRuleTarget = 4; - break; - } - if (object.loadBalancerId != null) - message.loadBalancerId = String(object.loadBalancerId); - switch (object.loadBalancerType) { - default: - if (typeof object.loadBalancerType === "number") { - message.loadBalancerType = object.loadBalancerType; - break; - } - break; - case "LOAD_BALANCER_TYPE_UNSPECIFIED": - case 0: - message.loadBalancerType = 0; - break; - case "HTTPS_ADVANCED_LOAD_BALANCER": - case 1: - message.loadBalancerType = 1; - break; - case "HTTPS_LOAD_BALANCER": - case 2: - message.loadBalancerType = 2; - break; - case "REGIONAL_HTTPS_LOAD_BALANCER": - case 3: - message.loadBalancerType = 3; - break; - case "INTERNAL_HTTPS_LOAD_BALANCER": - case 4: - message.loadBalancerType = 4; - break; - case "SSL_PROXY_LOAD_BALANCER": - case 5: - message.loadBalancerType = 5; - break; - case "TCP_PROXY_LOAD_BALANCER": - case 6: - message.loadBalancerType = 6; - break; - case "INTERNAL_TCP_PROXY_LOAD_BALANCER": - case 7: - message.loadBalancerType = 7; - break; - case "NETWORK_LOAD_BALANCER": - case 8: - message.loadBalancerType = 8; - break; - case "LEGACY_NETWORK_LOAD_BALANCER": - case 9: - message.loadBalancerType = 9; - break; - case "TCP_UDP_INTERNAL_LOAD_BALANCER": - case 10: - message.loadBalancerType = 10; - break; - } - if (object.gkeMasterCluster != null) - message.gkeMasterCluster = String(object.gkeMasterCluster); - if (object.cloudSqlInstance != null) - message.cloudSqlInstance = String(object.cloudSqlInstance); - if (object.cloudFunction != null) { - if (typeof object.cloudFunction !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.cloudFunction: object expected"); - message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.fromObject(object.cloudFunction); - } - if (object.appEngineVersion != null) { - if (typeof object.appEngineVersion !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.appEngineVersion: object expected"); - message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.fromObject(object.appEngineVersion); - } - if (object.cloudRunRevision != null) { - if (typeof object.cloudRunRevision !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.cloudRunRevision: object expected"); - message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.fromObject(object.cloudRunRevision); + var message = new $root.google.cloud.networkmanagement.v1.OperationMetadata(); + if (object.createTime != null) { + if (typeof object.createTime !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.OperationMetadata.createTime: object expected"); + message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); } - if (object.network != null) - message.network = String(object.network); - switch (object.networkType) { - default: - if (typeof object.networkType === "number") { - message.networkType = object.networkType; - break; - } - break; - case "NETWORK_TYPE_UNSPECIFIED": - case 0: - message.networkType = 0; - break; - case "GCP_NETWORK": - case 1: - message.networkType = 1; - break; - case "NON_GCP_NETWORK": - case 2: - message.networkType = 2; - break; + if (object.endTime != null) { + if (typeof object.endTime !== "object") + throw TypeError(".google.cloud.networkmanagement.v1.OperationMetadata.endTime: object expected"); + message.endTime = $root.google.protobuf.Timestamp.fromObject(object.endTime); } - if (object.projectId != null) - message.projectId = String(object.projectId); + if (object.target != null) + message.target = String(object.target); + if (object.verb != null) + message.verb = String(object.verb); + if (object.statusDetail != null) + message.statusDetail = String(object.statusDetail); + if (object.cancelRequested != null) + message.cancelRequested = Boolean(object.cancelRequested); + if (object.apiVersion != null) + message.apiVersion = String(object.apiVersion); return message; }; /** - * Creates a plain object from an Endpoint message. Also converts values to other types if specified. + * Creates a plain object from an OperationMetadata message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint} message Endpoint + * @param {google.cloud.networkmanagement.v1.OperationMetadata} message OperationMetadata * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Endpoint.toObject = function toObject(message, options) { + OperationMetadata.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.ipAddress = ""; - object.port = 0; - object.instance = ""; - object.network = ""; - object.networkType = options.enums === String ? "NETWORK_TYPE_UNSPECIFIED" : 0; - object.projectId = ""; - object.gkeMasterCluster = ""; - object.cloudSqlInstance = ""; - object.cloudFunction = null; - object.appEngineVersion = null; - object.cloudRunRevision = null; - object.forwardingRule = ""; - } - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - object.ipAddress = message.ipAddress; - if (message.port != null && message.hasOwnProperty("port")) - object.port = message.port; - if (message.instance != null && message.hasOwnProperty("instance")) - object.instance = message.instance; - if (message.network != null && message.hasOwnProperty("network")) - object.network = message.network; - if (message.networkType != null && message.hasOwnProperty("networkType")) - object.networkType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType[message.networkType] === undefined ? message.networkType : $root.google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType[message.networkType] : message.networkType; - if (message.projectId != null && message.hasOwnProperty("projectId")) - object.projectId = message.projectId; - if (message.gkeMasterCluster != null && message.hasOwnProperty("gkeMasterCluster")) - object.gkeMasterCluster = message.gkeMasterCluster; - if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) - object.cloudSqlInstance = message.cloudSqlInstance; - if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) - object.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.toObject(message.cloudFunction, options); - if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) - object.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.toObject(message.appEngineVersion, options); - if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) - object.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.toObject(message.cloudRunRevision, options); - if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) - object.forwardingRule = message.forwardingRule; - if (message.forwardingRuleTarget != null && message.hasOwnProperty("forwardingRuleTarget")) { - object.forwardingRuleTarget = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget[message.forwardingRuleTarget] === undefined ? message.forwardingRuleTarget : $root.google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget[message.forwardingRuleTarget] : message.forwardingRuleTarget; - if (options.oneofs) - object._forwardingRuleTarget = "forwardingRuleTarget"; - } - if (message.loadBalancerId != null && message.hasOwnProperty("loadBalancerId")) { - object.loadBalancerId = message.loadBalancerId; - if (options.oneofs) - object._loadBalancerId = "loadBalancerId"; - } - if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) { - object.loadBalancerType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerType[message.loadBalancerType] === undefined ? message.loadBalancerType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerType[message.loadBalancerType] : message.loadBalancerType; - if (options.oneofs) - object._loadBalancerType = "loadBalancerType"; + object.createTime = null; + object.endTime = null; + object.target = ""; + object.verb = ""; + object.statusDetail = ""; + object.cancelRequested = false; + object.apiVersion = ""; } + if (message.createTime != null && message.hasOwnProperty("createTime")) + object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); + if (message.endTime != null && message.hasOwnProperty("endTime")) + object.endTime = $root.google.protobuf.Timestamp.toObject(message.endTime, options); + if (message.target != null && message.hasOwnProperty("target")) + object.target = message.target; + if (message.verb != null && message.hasOwnProperty("verb")) + object.verb = message.verb; + if (message.statusDetail != null && message.hasOwnProperty("statusDetail")) + object.statusDetail = message.statusDetail; + if (message.cancelRequested != null && message.hasOwnProperty("cancelRequested")) + object.cancelRequested = message.cancelRequested; + if (message.apiVersion != null && message.hasOwnProperty("apiVersion")) + object.apiVersion = message.apiVersion; return object; }; /** - * Converts this Endpoint to JSON. + * Converts this OperationMetadata to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @instance * @returns {Object.} JSON object */ - Endpoint.prototype.toJSON = function toJSON() { + OperationMetadata.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Endpoint + * Gets the default type url for OperationMetadata * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @memberof google.cloud.networkmanagement.v1.OperationMetadata * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Endpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + OperationMetadata.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1.OperationMetadata"; }; + return OperationMetadata; + })(); + + return v1; + })(); + + networkmanagement.v1beta1 = (function() { + + /** + * Namespace v1beta1. + * @memberof google.cloud.networkmanagement + * @namespace + */ + var v1beta1 = {}; + + v1beta1.ConnectivityTest = (function() { + /** - * NetworkType enum. - * @name google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType - * @enum {number} - * @property {number} NETWORK_TYPE_UNSPECIFIED=0 NETWORK_TYPE_UNSPECIFIED value - * @property {number} GCP_NETWORK=1 GCP_NETWORK value - * @property {number} NON_GCP_NETWORK=2 NON_GCP_NETWORK value + * Properties of a ConnectivityTest. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IConnectivityTest + * @property {string|null} [name] ConnectivityTest name + * @property {string|null} [description] ConnectivityTest description + * @property {google.cloud.networkmanagement.v1beta1.IEndpoint|null} [source] ConnectivityTest source + * @property {google.cloud.networkmanagement.v1beta1.IEndpoint|null} [destination] ConnectivityTest destination + * @property {string|null} [protocol] ConnectivityTest protocol + * @property {Array.|null} [relatedProjects] ConnectivityTest relatedProjects + * @property {string|null} [displayName] ConnectivityTest displayName + * @property {Object.|null} [labels] ConnectivityTest labels + * @property {google.protobuf.ITimestamp|null} [createTime] ConnectivityTest createTime + * @property {google.protobuf.ITimestamp|null} [updateTime] ConnectivityTest updateTime + * @property {google.cloud.networkmanagement.v1beta1.IReachabilityDetails|null} [reachabilityDetails] ConnectivityTest reachabilityDetails + * @property {google.cloud.networkmanagement.v1beta1.IProbingDetails|null} [probingDetails] ConnectivityTest probingDetails + * @property {boolean|null} [bypassFirewallChecks] ConnectivityTest bypassFirewallChecks */ - Endpoint.NetworkType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "NETWORK_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "GCP_NETWORK"] = 1; - values[valuesById[2] = "NON_GCP_NETWORK"] = 2; - return values; - })(); /** - * ForwardingRuleTarget enum. - * @name google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget - * @enum {number} - * @property {number} FORWARDING_RULE_TARGET_UNSPECIFIED=0 FORWARDING_RULE_TARGET_UNSPECIFIED value - * @property {number} INSTANCE=1 INSTANCE value - * @property {number} LOAD_BALANCER=2 LOAD_BALANCER value - * @property {number} VPN_GATEWAY=3 VPN_GATEWAY value - * @property {number} PSC=4 PSC value + * Constructs a new ConnectivityTest. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a ConnectivityTest. + * @implements IConnectivityTest + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest=} [properties] Properties to set */ - Endpoint.ForwardingRuleTarget = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "FORWARDING_RULE_TARGET_UNSPECIFIED"] = 0; - values[valuesById[1] = "INSTANCE"] = 1; - values[valuesById[2] = "LOAD_BALANCER"] = 2; - values[valuesById[3] = "VPN_GATEWAY"] = 3; - values[valuesById[4] = "PSC"] = 4; - return values; - })(); + function ConnectivityTest(properties) { + this.relatedProjects = []; + this.labels = {}; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - Endpoint.CloudFunctionEndpoint = (function() { + /** + * ConnectivityTest name. + * @member {string} name + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.name = ""; - /** - * Properties of a CloudFunctionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @interface ICloudFunctionEndpoint - * @property {string|null} [uri] CloudFunctionEndpoint uri - */ + /** + * ConnectivityTest description. + * @member {string} description + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.description = ""; - /** - * Constructs a new CloudFunctionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @classdesc Represents a CloudFunctionEndpoint. - * @implements ICloudFunctionEndpoint - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint=} [properties] Properties to set - */ - function CloudFunctionEndpoint(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * ConnectivityTest source. + * @member {google.cloud.networkmanagement.v1beta1.IEndpoint|null|undefined} source + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.source = null; - /** - * CloudFunctionEndpoint uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @instance - */ - CloudFunctionEndpoint.prototype.uri = ""; + /** + * ConnectivityTest destination. + * @member {google.cloud.networkmanagement.v1beta1.IEndpoint|null|undefined} destination + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.destination = null; - /** - * Creates a new CloudFunctionEndpoint instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint instance - */ - CloudFunctionEndpoint.create = function create(properties) { - return new CloudFunctionEndpoint(properties); - }; + /** + * ConnectivityTest protocol. + * @member {string} protocol + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.protocol = ""; - /** - * Encodes the specified CloudFunctionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint} message CloudFunctionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CloudFunctionEndpoint.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); - return writer; - }; + /** + * ConnectivityTest relatedProjects. + * @member {Array.} relatedProjects + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.relatedProjects = $util.emptyArray; - /** - * Encodes the specified CloudFunctionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint} message CloudFunctionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CloudFunctionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * ConnectivityTest displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.displayName = ""; - /** - * Decodes a CloudFunctionEndpoint message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CloudFunctionEndpoint.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.uri = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a CloudFunctionEndpoint message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CloudFunctionEndpoint.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a CloudFunctionEndpoint message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - CloudFunctionEndpoint.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - return null; - }; - - /** - * Creates a CloudFunctionEndpoint message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint - */ - CloudFunctionEndpoint.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint(); - if (object.uri != null) - message.uri = String(object.uri); - return message; - }; - - /** - * Creates a plain object from a CloudFunctionEndpoint message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} message CloudFunctionEndpoint - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - CloudFunctionEndpoint.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.uri = ""; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - return object; - }; + /** + * ConnectivityTest labels. + * @member {Object.} labels + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.labels = $util.emptyObject; - /** - * Converts this CloudFunctionEndpoint to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @instance - * @returns {Object.} JSON object - */ - CloudFunctionEndpoint.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * ConnectivityTest createTime. + * @member {google.protobuf.ITimestamp|null|undefined} createTime + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.createTime = null; - /** - * Gets the default type url for CloudFunctionEndpoint - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - CloudFunctionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint"; - }; + /** + * ConnectivityTest updateTime. + * @member {google.protobuf.ITimestamp|null|undefined} updateTime + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.updateTime = null; - return CloudFunctionEndpoint; - })(); + /** + * ConnectivityTest reachabilityDetails. + * @member {google.cloud.networkmanagement.v1beta1.IReachabilityDetails|null|undefined} reachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.reachabilityDetails = null; - Endpoint.AppEngineVersionEndpoint = (function() { + /** + * ConnectivityTest probingDetails. + * @member {google.cloud.networkmanagement.v1beta1.IProbingDetails|null|undefined} probingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.probingDetails = null; - /** - * Properties of an AppEngineVersionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @interface IAppEngineVersionEndpoint - * @property {string|null} [uri] AppEngineVersionEndpoint uri - */ + /** + * ConnectivityTest bypassFirewallChecks. + * @member {boolean} bypassFirewallChecks + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + */ + ConnectivityTest.prototype.bypassFirewallChecks = false; - /** - * Constructs a new AppEngineVersionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @classdesc Represents an AppEngineVersionEndpoint. - * @implements IAppEngineVersionEndpoint - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint=} [properties] Properties to set - */ - function AppEngineVersionEndpoint(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Creates a new ConnectivityTest instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest instance + */ + ConnectivityTest.create = function create(properties) { + return new ConnectivityTest(properties); + }; - /** - * AppEngineVersionEndpoint uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @instance - */ - AppEngineVersionEndpoint.prototype.uri = ""; + /** + * Encodes the specified ConnectivityTest message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ConnectivityTest.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest} message ConnectivityTest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ConnectivityTest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); + if (message.source != null && Object.hasOwnProperty.call(message, "source")) + $root.google.cloud.networkmanagement.v1beta1.Endpoint.encode(message.source, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.destination != null && Object.hasOwnProperty.call(message, "destination")) + $root.google.cloud.networkmanagement.v1beta1.Endpoint.encode(message.destination, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.protocol); + if (message.relatedProjects != null && message.relatedProjects.length) + for (var i = 0; i < message.relatedProjects.length; ++i) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.relatedProjects[i]); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.displayName); + if (message.labels != null && Object.hasOwnProperty.call(message, "labels")) + for (var keys = Object.keys(message.labels), i = 0; i < keys.length; ++i) + writer.uint32(/* id 8, wireType 2 =*/66).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.labels[keys[i]]).ldelim(); + if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) + $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); + if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) + $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); + if (message.reachabilityDetails != null && Object.hasOwnProperty.call(message, "reachabilityDetails")) + $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.encode(message.reachabilityDetails, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); + if (message.probingDetails != null && Object.hasOwnProperty.call(message, "probingDetails")) + $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.encode(message.probingDetails, writer.uint32(/* id 14, wireType 2 =*/114).fork()).ldelim(); + if (message.bypassFirewallChecks != null && Object.hasOwnProperty.call(message, "bypassFirewallChecks")) + writer.uint32(/* id 17, wireType 0 =*/136).bool(message.bypassFirewallChecks); + return writer; + }; - /** - * Creates a new AppEngineVersionEndpoint instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint instance - */ - AppEngineVersionEndpoint.create = function create(properties) { - return new AppEngineVersionEndpoint(properties); - }; + /** + * Encodes the specified ConnectivityTest message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ConnectivityTest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {google.cloud.networkmanagement.v1beta1.IConnectivityTest} message ConnectivityTest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ConnectivityTest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Encodes the specified AppEngineVersionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint} message AppEngineVersionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AppEngineVersionEndpoint.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); - return writer; - }; - - /** - * Encodes the specified AppEngineVersionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint} message AppEngineVersionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AppEngineVersionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an AppEngineVersionEndpoint message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AppEngineVersionEndpoint.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.uri = reader.string(); - break; + /** + * Decodes a ConnectivityTest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ConnectivityTest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest(), key, value; + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + case 2: { + message.description = reader.string(); + break; + } + case 3: { + message.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.decode(reader, reader.uint32()); + break; + } + case 4: { + message.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.decode(reader, reader.uint32()); + break; + } + case 5: { + message.protocol = reader.string(); + break; + } + case 6: { + if (!(message.relatedProjects && message.relatedProjects.length)) + message.relatedProjects = []; + message.relatedProjects.push(reader.string()); + break; + } + case 7: { + message.displayName = reader.string(); + break; + } + case 8: { + if (message.labels === $util.emptyObject) + message.labels = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = ""; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = reader.string(); + break; + default: + reader.skipType(tag2 & 7); + break; + } } - default: - reader.skipType(tag & 7); + message.labels[key] = value; + break; + } + case 10: { + message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 11: { + message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 12: { + message.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.decode(reader, reader.uint32()); + break; + } + case 14: { + message.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.decode(reader, reader.uint32()); + break; + } + case 17: { + message.bypassFirewallChecks = reader.bool(); break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes an AppEngineVersionEndpoint message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AppEngineVersionEndpoint.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an AppEngineVersionEndpoint message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - AppEngineVersionEndpoint.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - return null; - }; - - /** - * Creates an AppEngineVersionEndpoint message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint - */ - AppEngineVersionEndpoint.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint(); - if (object.uri != null) - message.uri = String(object.uri); - return message; - }; - - /** - * Creates a plain object from an AppEngineVersionEndpoint message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} message AppEngineVersionEndpoint - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - AppEngineVersionEndpoint.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.uri = ""; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - return object; - }; - - /** - * Converts this AppEngineVersionEndpoint to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @instance - * @returns {Object.} JSON object - */ - AppEngineVersionEndpoint.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + } + return message; + }; - /** - * Gets the default type url for AppEngineVersionEndpoint - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - AppEngineVersionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint"; - }; + /** + * Decodes a ConnectivityTest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ConnectivityTest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - return AppEngineVersionEndpoint; - })(); - - Endpoint.CloudRunRevisionEndpoint = (function() { + /** + * Verifies a ConnectivityTest message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ConnectivityTest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.source != null && message.hasOwnProperty("source")) { + var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.verify(message.source); + if (error) + return "source." + error; + } + if (message.destination != null && message.hasOwnProperty("destination")) { + var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.verify(message.destination); + if (error) + return "destination." + error; + } + if (message.protocol != null && message.hasOwnProperty("protocol")) + if (!$util.isString(message.protocol)) + return "protocol: string expected"; + if (message.relatedProjects != null && message.hasOwnProperty("relatedProjects")) { + if (!Array.isArray(message.relatedProjects)) + return "relatedProjects: array expected"; + for (var i = 0; i < message.relatedProjects.length; ++i) + if (!$util.isString(message.relatedProjects[i])) + return "relatedProjects: string[] expected"; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.labels != null && message.hasOwnProperty("labels")) { + if (!$util.isObject(message.labels)) + return "labels: object expected"; + var key = Object.keys(message.labels); + for (var i = 0; i < key.length; ++i) + if (!$util.isString(message.labels[key[i]])) + return "labels: string{k:string} expected"; + } + if (message.createTime != null && message.hasOwnProperty("createTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.createTime); + if (error) + return "createTime." + error; + } + if (message.updateTime != null && message.hasOwnProperty("updateTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.updateTime); + if (error) + return "updateTime." + error; + } + if (message.reachabilityDetails != null && message.hasOwnProperty("reachabilityDetails")) { + var error = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify(message.reachabilityDetails); + if (error) + return "reachabilityDetails." + error; + } + if (message.probingDetails != null && message.hasOwnProperty("probingDetails")) { + var error = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.verify(message.probingDetails); + if (error) + return "probingDetails." + error; + } + if (message.bypassFirewallChecks != null && message.hasOwnProperty("bypassFirewallChecks")) + if (typeof message.bypassFirewallChecks !== "boolean") + return "bypassFirewallChecks: boolean expected"; + return null; + }; - /** - * Properties of a CloudRunRevisionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @interface ICloudRunRevisionEndpoint - * @property {string|null} [uri] CloudRunRevisionEndpoint uri - */ + /** + * Creates a ConnectivityTest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.ConnectivityTest} ConnectivityTest + */ + ConnectivityTest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.ConnectivityTest(); + if (object.name != null) + message.name = String(object.name); + if (object.description != null) + message.description = String(object.description); + if (object.source != null) { + if (typeof object.source !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.source: object expected"); + message.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.fromObject(object.source); + } + if (object.destination != null) { + if (typeof object.destination !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.destination: object expected"); + message.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.fromObject(object.destination); + } + if (object.protocol != null) + message.protocol = String(object.protocol); + if (object.relatedProjects) { + if (!Array.isArray(object.relatedProjects)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.relatedProjects: array expected"); + message.relatedProjects = []; + for (var i = 0; i < object.relatedProjects.length; ++i) + message.relatedProjects[i] = String(object.relatedProjects[i]); + } + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.labels) { + if (typeof object.labels !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.labels: object expected"); + message.labels = {}; + for (var keys = Object.keys(object.labels), i = 0; i < keys.length; ++i) + message.labels[keys[i]] = String(object.labels[keys[i]]); + } + if (object.createTime != null) { + if (typeof object.createTime !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.createTime: object expected"); + message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); + } + if (object.updateTime != null) { + if (typeof object.updateTime !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.updateTime: object expected"); + message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); + } + if (object.reachabilityDetails != null) { + if (typeof object.reachabilityDetails !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.reachabilityDetails: object expected"); + message.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.fromObject(object.reachabilityDetails); + } + if (object.probingDetails != null) { + if (typeof object.probingDetails !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ConnectivityTest.probingDetails: object expected"); + message.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.fromObject(object.probingDetails); + } + if (object.bypassFirewallChecks != null) + message.bypassFirewallChecks = Boolean(object.bypassFirewallChecks); + return message; + }; - /** - * Constructs a new CloudRunRevisionEndpoint. - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint - * @classdesc Represents a CloudRunRevisionEndpoint. - * @implements ICloudRunRevisionEndpoint - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint=} [properties] Properties to set - */ - function CloudRunRevisionEndpoint(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Creates a plain object from a ConnectivityTest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {google.cloud.networkmanagement.v1beta1.ConnectivityTest} message ConnectivityTest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ConnectivityTest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.relatedProjects = []; + if (options.objects || options.defaults) + object.labels = {}; + if (options.defaults) { + object.name = ""; + object.description = ""; + object.source = null; + object.destination = null; + object.protocol = ""; + object.displayName = ""; + object.createTime = null; + object.updateTime = null; + object.reachabilityDetails = null; + object.probingDetails = null; + object.bypassFirewallChecks = false; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.source != null && message.hasOwnProperty("source")) + object.source = $root.google.cloud.networkmanagement.v1beta1.Endpoint.toObject(message.source, options); + if (message.destination != null && message.hasOwnProperty("destination")) + object.destination = $root.google.cloud.networkmanagement.v1beta1.Endpoint.toObject(message.destination, options); + if (message.protocol != null && message.hasOwnProperty("protocol")) + object.protocol = message.protocol; + if (message.relatedProjects && message.relatedProjects.length) { + object.relatedProjects = []; + for (var j = 0; j < message.relatedProjects.length; ++j) + object.relatedProjects[j] = message.relatedProjects[j]; } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + var keys2; + if (message.labels && (keys2 = Object.keys(message.labels)).length) { + object.labels = {}; + for (var j = 0; j < keys2.length; ++j) + object.labels[keys2[j]] = message.labels[keys2[j]]; + } + if (message.createTime != null && message.hasOwnProperty("createTime")) + object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); + if (message.updateTime != null && message.hasOwnProperty("updateTime")) + object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); + if (message.reachabilityDetails != null && message.hasOwnProperty("reachabilityDetails")) + object.reachabilityDetails = $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.toObject(message.reachabilityDetails, options); + if (message.probingDetails != null && message.hasOwnProperty("probingDetails")) + object.probingDetails = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.toObject(message.probingDetails, options); + if (message.bypassFirewallChecks != null && message.hasOwnProperty("bypassFirewallChecks")) + object.bypassFirewallChecks = message.bypassFirewallChecks; + return object; + }; - /** - * CloudRunRevisionEndpoint uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @instance - */ - CloudRunRevisionEndpoint.prototype.uri = ""; + /** + * Converts this ConnectivityTest to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @instance + * @returns {Object.} JSON object + */ + ConnectivityTest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Creates a new CloudRunRevisionEndpoint instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint instance - */ - CloudRunRevisionEndpoint.create = function create(properties) { - return new CloudRunRevisionEndpoint(properties); - }; - - /** - * Encodes the specified CloudRunRevisionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint} message CloudRunRevisionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CloudRunRevisionEndpoint.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); - return writer; - }; - - /** - * Encodes the specified CloudRunRevisionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint} message CloudRunRevisionEndpoint message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CloudRunRevisionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a CloudRunRevisionEndpoint message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CloudRunRevisionEndpoint.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.uri = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a CloudRunRevisionEndpoint message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CloudRunRevisionEndpoint.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a CloudRunRevisionEndpoint message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - CloudRunRevisionEndpoint.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - return null; - }; - - /** - * Creates a CloudRunRevisionEndpoint message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint - */ - CloudRunRevisionEndpoint.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint(); - if (object.uri != null) - message.uri = String(object.uri); - return message; - }; - - /** - * Creates a plain object from a CloudRunRevisionEndpoint message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} message CloudRunRevisionEndpoint - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - CloudRunRevisionEndpoint.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.uri = ""; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - return object; - }; - - /** - * Converts this CloudRunRevisionEndpoint to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @instance - * @returns {Object.} JSON object - */ - CloudRunRevisionEndpoint.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for CloudRunRevisionEndpoint - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - CloudRunRevisionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint"; - }; - - return CloudRunRevisionEndpoint; - })(); + /** + * Gets the default type url for ConnectivityTest + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.ConnectivityTest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ConnectivityTest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ConnectivityTest"; + }; - return Endpoint; + return ConnectivityTest; })(); - v1beta1.ReachabilityDetails = (function() { + v1beta1.Endpoint = (function() { /** - * Properties of a ReachabilityDetails. + * Properties of an Endpoint. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IReachabilityDetails - * @property {google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result|null} [result] ReachabilityDetails result - * @property {google.protobuf.ITimestamp|null} [verifyTime] ReachabilityDetails verifyTime - * @property {google.rpc.IStatus|null} [error] ReachabilityDetails error - * @property {Array.|null} [traces] ReachabilityDetails traces + * @interface IEndpoint + * @property {string|null} [ipAddress] Endpoint ipAddress + * @property {number|null} [port] Endpoint port + * @property {string|null} [instance] Endpoint instance + * @property {string|null} [forwardingRule] Endpoint forwardingRule + * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget|null} [forwardingRuleTarget] Endpoint forwardingRuleTarget + * @property {string|null} [loadBalancerId] Endpoint loadBalancerId + * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerType|null} [loadBalancerType] Endpoint loadBalancerType + * @property {string|null} [gkeMasterCluster] Endpoint gkeMasterCluster + * @property {string|null} [cloudSqlInstance] Endpoint cloudSqlInstance + * @property {string|null} [redisInstance] Endpoint redisInstance + * @property {string|null} [redisCluster] Endpoint redisCluster + * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null} [cloudFunction] Endpoint cloudFunction + * @property {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint|null} [appEngineVersion] Endpoint appEngineVersion + * @property {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint|null} [cloudRunRevision] Endpoint cloudRunRevision + * @property {string|null} [network] Endpoint network + * @property {google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType|null} [networkType] Endpoint networkType + * @property {string|null} [projectId] Endpoint projectId */ /** - * Constructs a new ReachabilityDetails. + * Constructs a new Endpoint. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a ReachabilityDetails. - * @implements IReachabilityDetails + * @classdesc Represents an Endpoint. + * @implements IEndpoint * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IEndpoint=} [properties] Properties to set */ - function ReachabilityDetails(properties) { - this.traces = []; + function Endpoint(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -19299,827 +19513,1390 @@ } /** - * ReachabilityDetails result. - * @member {google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result} result - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * Endpoint ipAddress. + * @member {string} ipAddress + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @instance */ - ReachabilityDetails.prototype.result = 0; + Endpoint.prototype.ipAddress = ""; /** - * ReachabilityDetails verifyTime. - * @member {google.protobuf.ITimestamp|null|undefined} verifyTime - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * Endpoint port. + * @member {number} port + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @instance */ - ReachabilityDetails.prototype.verifyTime = null; + Endpoint.prototype.port = 0; /** - * ReachabilityDetails error. - * @member {google.rpc.IStatus|null|undefined} error - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * Endpoint instance. + * @member {string} instance + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @instance */ - ReachabilityDetails.prototype.error = null; + Endpoint.prototype.instance = ""; /** - * ReachabilityDetails traces. - * @member {Array.} traces - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * Endpoint forwardingRule. + * @member {string} forwardingRule + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @instance */ - ReachabilityDetails.prototype.traces = $util.emptyArray; + Endpoint.prototype.forwardingRule = ""; /** - * Creates a new ReachabilityDetails instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails - * @static - * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails instance + * Endpoint forwardingRuleTarget. + * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget|null|undefined} forwardingRuleTarget + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance */ - ReachabilityDetails.create = function create(properties) { - return new ReachabilityDetails(properties); - }; + Endpoint.prototype.forwardingRuleTarget = null; /** - * Encodes the specified ReachabilityDetails message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify|verify} messages. + * Endpoint loadBalancerId. + * @member {string|null|undefined} loadBalancerId + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.loadBalancerId = null; + + /** + * Endpoint loadBalancerType. + * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerType|null|undefined} loadBalancerType + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.loadBalancerType = null; + + /** + * Endpoint gkeMasterCluster. + * @member {string} gkeMasterCluster + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.gkeMasterCluster = ""; + + /** + * Endpoint cloudSqlInstance. + * @member {string} cloudSqlInstance + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.cloudSqlInstance = ""; + + /** + * Endpoint redisInstance. + * @member {string} redisInstance + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.redisInstance = ""; + + /** + * Endpoint redisCluster. + * @member {string} redisCluster + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.redisCluster = ""; + + /** + * Endpoint cloudFunction. + * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint|null|undefined} cloudFunction + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.cloudFunction = null; + + /** + * Endpoint appEngineVersion. + * @member {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint|null|undefined} appEngineVersion + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.appEngineVersion = null; + + /** + * Endpoint cloudRunRevision. + * @member {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint|null|undefined} cloudRunRevision + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.cloudRunRevision = null; + + /** + * Endpoint network. + * @member {string} network + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.network = ""; + + /** + * Endpoint networkType. + * @member {google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType} networkType + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.networkType = 0; + + /** + * Endpoint projectId. + * @member {string} projectId + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Endpoint.prototype.projectId = ""; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * Endpoint _forwardingRuleTarget. + * @member {"forwardingRuleTarget"|undefined} _forwardingRuleTarget + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Object.defineProperty(Endpoint.prototype, "_forwardingRuleTarget", { + get: $util.oneOfGetter($oneOfFields = ["forwardingRuleTarget"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Endpoint _loadBalancerId. + * @member {"loadBalancerId"|undefined} _loadBalancerId + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Object.defineProperty(Endpoint.prototype, "_loadBalancerId", { + get: $util.oneOfGetter($oneOfFields = ["loadBalancerId"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Endpoint _loadBalancerType. + * @member {"loadBalancerType"|undefined} _loadBalancerType + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @instance + */ + Object.defineProperty(Endpoint.prototype, "_loadBalancerType", { + get: $util.oneOfGetter($oneOfFields = ["loadBalancerType"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new Endpoint instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.IEndpoint=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint instance + */ + Endpoint.create = function create(properties) { + return new Endpoint(properties); + }; + + /** + * Encodes the specified Endpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static - * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails} message ReachabilityDetails message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IEndpoint} message Endpoint message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ReachabilityDetails.encode = function encode(message, writer) { + Endpoint.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.result != null && Object.hasOwnProperty.call(message, "result")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.result); - if (message.verifyTime != null && Object.hasOwnProperty.call(message, "verifyTime")) - $root.google.protobuf.Timestamp.encode(message.verifyTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.error != null && Object.hasOwnProperty.call(message, "error")) - $root.google.rpc.Status.encode(message.error, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.traces != null && message.traces.length) - for (var i = 0; i < message.traces.length; ++i) - $root.google.cloud.networkmanagement.v1beta1.Trace.encode(message.traces[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.ipAddress); + if (message.port != null && Object.hasOwnProperty.call(message, "port")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.port); + if (message.instance != null && Object.hasOwnProperty.call(message, "instance")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.instance); + if (message.network != null && Object.hasOwnProperty.call(message, "network")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.network); + if (message.networkType != null && Object.hasOwnProperty.call(message, "networkType")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.networkType); + if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.projectId); + if (message.gkeMasterCluster != null && Object.hasOwnProperty.call(message, "gkeMasterCluster")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.gkeMasterCluster); + if (message.cloudSqlInstance != null && Object.hasOwnProperty.call(message, "cloudSqlInstance")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.cloudSqlInstance); + if (message.cloudFunction != null && Object.hasOwnProperty.call(message, "cloudFunction")) + $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.encode(message.cloudFunction, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); + if (message.appEngineVersion != null && Object.hasOwnProperty.call(message, "appEngineVersion")) + $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.encode(message.appEngineVersion, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); + if (message.cloudRunRevision != null && Object.hasOwnProperty.call(message, "cloudRunRevision")) + $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.encode(message.cloudRunRevision, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); + if (message.forwardingRule != null && Object.hasOwnProperty.call(message, "forwardingRule")) + writer.uint32(/* id 13, wireType 2 =*/106).string(message.forwardingRule); + if (message.forwardingRuleTarget != null && Object.hasOwnProperty.call(message, "forwardingRuleTarget")) + writer.uint32(/* id 14, wireType 0 =*/112).int32(message.forwardingRuleTarget); + if (message.loadBalancerId != null && Object.hasOwnProperty.call(message, "loadBalancerId")) + writer.uint32(/* id 15, wireType 2 =*/122).string(message.loadBalancerId); + if (message.loadBalancerType != null && Object.hasOwnProperty.call(message, "loadBalancerType")) + writer.uint32(/* id 16, wireType 0 =*/128).int32(message.loadBalancerType); + if (message.redisInstance != null && Object.hasOwnProperty.call(message, "redisInstance")) + writer.uint32(/* id 17, wireType 2 =*/138).string(message.redisInstance); + if (message.redisCluster != null && Object.hasOwnProperty.call(message, "redisCluster")) + writer.uint32(/* id 18, wireType 2 =*/146).string(message.redisCluster); return writer; }; /** - * Encodes the specified ReachabilityDetails message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify|verify} messages. + * Encodes the specified Endpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static - * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails} message ReachabilityDetails message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IEndpoint} message Endpoint message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ReachabilityDetails.encodeDelimited = function encodeDelimited(message, writer) { + Endpoint.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ReachabilityDetails message from the specified reader or buffer. + * Decodes an Endpoint message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ReachabilityDetails.decode = function decode(reader, length) { + Endpoint.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.result = reader.int32(); + message.ipAddress = reader.string(); break; } case 2: { - message.verifyTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.port = reader.int32(); break; } case 3: { - message.error = $root.google.rpc.Status.decode(reader, reader.uint32()); + message.instance = reader.string(); break; } - case 5: { - if (!(message.traces && message.traces.length)) - message.traces = []; - message.traces.push($root.google.cloud.networkmanagement.v1beta1.Trace.decode(reader, reader.uint32())); + case 13: { + message.forwardingRule = reader.string(); break; } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ReachabilityDetails message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ReachabilityDetails.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ReachabilityDetails message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ReachabilityDetails.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.result != null && message.hasOwnProperty("result")) - switch (message.result) { - default: - return "result: enum value expected"; - case 0: + case 14: { + message.forwardingRuleTarget = reader.int32(); + break; + } + case 15: { + message.loadBalancerId = reader.string(); + break; + } + case 16: { + message.loadBalancerType = reader.int32(); + break; + } + case 7: { + message.gkeMasterCluster = reader.string(); + break; + } + case 8: { + message.cloudSqlInstance = reader.string(); + break; + } + case 17: { + message.redisInstance = reader.string(); + break; + } + case 18: { + message.redisCluster = reader.string(); + break; + } + case 10: { + message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.decode(reader, reader.uint32()); + break; + } + case 11: { + message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.decode(reader, reader.uint32()); + break; + } + case 12: { + message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.decode(reader, reader.uint32()); + break; + } + case 4: { + message.network = reader.string(); + break; + } + case 5: { + message.networkType = reader.int32(); + break; + } + case 6: { + message.projectId = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an Endpoint message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Endpoint.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an Endpoint message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Endpoint.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + if (!$util.isString(message.ipAddress)) + return "ipAddress: string expected"; + if (message.port != null && message.hasOwnProperty("port")) + if (!$util.isInteger(message.port)) + return "port: integer expected"; + if (message.instance != null && message.hasOwnProperty("instance")) + if (!$util.isString(message.instance)) + return "instance: string expected"; + if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) + if (!$util.isString(message.forwardingRule)) + return "forwardingRule: string expected"; + if (message.forwardingRuleTarget != null && message.hasOwnProperty("forwardingRuleTarget")) { + properties._forwardingRuleTarget = 1; + switch (message.forwardingRuleTarget) { + default: + return "forwardingRuleTarget: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + break; + } + } + if (message.loadBalancerId != null && message.hasOwnProperty("loadBalancerId")) { + properties._loadBalancerId = 1; + if (!$util.isString(message.loadBalancerId)) + return "loadBalancerId: string expected"; + } + if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) { + properties._loadBalancerType = 1; + switch (message.loadBalancerType) { + default: + return "loadBalancerType: enum value expected"; + case 0: case 1: case 2: + case 3: case 4: case 5: + case 6: + case 7: + case 8: + case 9: + case 10: break; } - if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.verifyTime); + } + if (message.gkeMasterCluster != null && message.hasOwnProperty("gkeMasterCluster")) + if (!$util.isString(message.gkeMasterCluster)) + return "gkeMasterCluster: string expected"; + if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) + if (!$util.isString(message.cloudSqlInstance)) + return "cloudSqlInstance: string expected"; + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) + if (!$util.isString(message.redisInstance)) + return "redisInstance: string expected"; + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) + if (!$util.isString(message.redisCluster)) + return "redisCluster: string expected"; + if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { + var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify(message.cloudFunction); if (error) - return "verifyTime." + error; + return "cloudFunction." + error; } - if (message.error != null && message.hasOwnProperty("error")) { - var error = $root.google.rpc.Status.verify(message.error); + if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { + var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify(message.appEngineVersion); if (error) - return "error." + error; + return "appEngineVersion." + error; } - if (message.traces != null && message.hasOwnProperty("traces")) { - if (!Array.isArray(message.traces)) - return "traces: array expected"; - for (var i = 0; i < message.traces.length; ++i) { - var error = $root.google.cloud.networkmanagement.v1beta1.Trace.verify(message.traces[i]); - if (error) - return "traces." + error; - } + if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { + var error = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify(message.cloudRunRevision); + if (error) + return "cloudRunRevision." + error; } + if (message.network != null && message.hasOwnProperty("network")) + if (!$util.isString(message.network)) + return "network: string expected"; + if (message.networkType != null && message.hasOwnProperty("networkType")) + switch (message.networkType) { + default: + return "networkType: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.projectId != null && message.hasOwnProperty("projectId")) + if (!$util.isString(message.projectId)) + return "projectId: string expected"; return null; }; /** - * Creates a ReachabilityDetails message from a plain object. Also converts values to their respective internal types. + * Creates an Endpoint message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint} Endpoint */ - ReachabilityDetails.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails) + Endpoint.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails(); - switch (object.result) { + var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint(); + if (object.ipAddress != null) + message.ipAddress = String(object.ipAddress); + if (object.port != null) + message.port = object.port | 0; + if (object.instance != null) + message.instance = String(object.instance); + if (object.forwardingRule != null) + message.forwardingRule = String(object.forwardingRule); + switch (object.forwardingRuleTarget) { default: - if (typeof object.result === "number") { - message.result = object.result; + if (typeof object.forwardingRuleTarget === "number") { + message.forwardingRuleTarget = object.forwardingRuleTarget; break; } break; - case "RESULT_UNSPECIFIED": + case "FORWARDING_RULE_TARGET_UNSPECIFIED": case 0: - message.result = 0; + message.forwardingRuleTarget = 0; break; - case "REACHABLE": + case "INSTANCE": case 1: - message.result = 1; + message.forwardingRuleTarget = 1; break; - case "UNREACHABLE": + case "LOAD_BALANCER": case 2: - message.result = 2; + message.forwardingRuleTarget = 2; break; - case "AMBIGUOUS": - case 4: - message.result = 4; + case "VPN_GATEWAY": + case 3: + message.forwardingRuleTarget = 3; break; - case "UNDETERMINED": - case 5: - message.result = 5; + case "PSC": + case 4: + message.forwardingRuleTarget = 4; break; } - if (object.verifyTime != null) { - if (typeof object.verifyTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verifyTime: object expected"); - message.verifyTime = $root.google.protobuf.Timestamp.fromObject(object.verifyTime); - } - if (object.error != null) { - if (typeof object.error !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.error: object expected"); - message.error = $root.google.rpc.Status.fromObject(object.error); - } - if (object.traces) { - if (!Array.isArray(object.traces)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.traces: array expected"); - message.traces = []; - for (var i = 0; i < object.traces.length; ++i) { - if (typeof object.traces[i] !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.traces: object expected"); - message.traces[i] = $root.google.cloud.networkmanagement.v1beta1.Trace.fromObject(object.traces[i]); + if (object.loadBalancerId != null) + message.loadBalancerId = String(object.loadBalancerId); + switch (object.loadBalancerType) { + default: + if (typeof object.loadBalancerType === "number") { + message.loadBalancerType = object.loadBalancerType; + break; } - } - return message; - }; - - /** - * Creates a plain object from a ReachabilityDetails message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + break; + case "LOAD_BALANCER_TYPE_UNSPECIFIED": + case 0: + message.loadBalancerType = 0; + break; + case "HTTPS_ADVANCED_LOAD_BALANCER": + case 1: + message.loadBalancerType = 1; + break; + case "HTTPS_LOAD_BALANCER": + case 2: + message.loadBalancerType = 2; + break; + case "REGIONAL_HTTPS_LOAD_BALANCER": + case 3: + message.loadBalancerType = 3; + break; + case "INTERNAL_HTTPS_LOAD_BALANCER": + case 4: + message.loadBalancerType = 4; + break; + case "SSL_PROXY_LOAD_BALANCER": + case 5: + message.loadBalancerType = 5; + break; + case "TCP_PROXY_LOAD_BALANCER": + case 6: + message.loadBalancerType = 6; + break; + case "INTERNAL_TCP_PROXY_LOAD_BALANCER": + case 7: + message.loadBalancerType = 7; + break; + case "NETWORK_LOAD_BALANCER": + case 8: + message.loadBalancerType = 8; + break; + case "LEGACY_NETWORK_LOAD_BALANCER": + case 9: + message.loadBalancerType = 9; + break; + case "TCP_UDP_INTERNAL_LOAD_BALANCER": + case 10: + message.loadBalancerType = 10; + break; + } + if (object.gkeMasterCluster != null) + message.gkeMasterCluster = String(object.gkeMasterCluster); + if (object.cloudSqlInstance != null) + message.cloudSqlInstance = String(object.cloudSqlInstance); + if (object.redisInstance != null) + message.redisInstance = String(object.redisInstance); + if (object.redisCluster != null) + message.redisCluster = String(object.redisCluster); + if (object.cloudFunction != null) { + if (typeof object.cloudFunction !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.cloudFunction: object expected"); + message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.fromObject(object.cloudFunction); + } + if (object.appEngineVersion != null) { + if (typeof object.appEngineVersion !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.appEngineVersion: object expected"); + message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.fromObject(object.appEngineVersion); + } + if (object.cloudRunRevision != null) { + if (typeof object.cloudRunRevision !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Endpoint.cloudRunRevision: object expected"); + message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.fromObject(object.cloudRunRevision); + } + if (object.network != null) + message.network = String(object.network); + switch (object.networkType) { + default: + if (typeof object.networkType === "number") { + message.networkType = object.networkType; + break; + } + break; + case "NETWORK_TYPE_UNSPECIFIED": + case 0: + message.networkType = 0; + break; + case "GCP_NETWORK": + case 1: + message.networkType = 1; + break; + case "NON_GCP_NETWORK": + case 2: + message.networkType = 2; + break; + } + if (object.projectId != null) + message.projectId = String(object.projectId); + return message; + }; + + /** + * Creates a plain object from an Endpoint message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static - * @param {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} message ReachabilityDetails + * @param {google.cloud.networkmanagement.v1beta1.Endpoint} message Endpoint * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ReachabilityDetails.toObject = function toObject(message, options) { + Endpoint.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.traces = []; if (options.defaults) { - object.result = options.enums === String ? "RESULT_UNSPECIFIED" : 0; - object.verifyTime = null; - object.error = null; + object.ipAddress = ""; + object.port = 0; + object.instance = ""; + object.network = ""; + object.networkType = options.enums === String ? "NETWORK_TYPE_UNSPECIFIED" : 0; + object.projectId = ""; + object.gkeMasterCluster = ""; + object.cloudSqlInstance = ""; + object.cloudFunction = null; + object.appEngineVersion = null; + object.cloudRunRevision = null; + object.forwardingRule = ""; + object.redisInstance = ""; + object.redisCluster = ""; } - if (message.result != null && message.hasOwnProperty("result")) - object.result = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result[message.result] === undefined ? message.result : $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result[message.result] : message.result; - if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) - object.verifyTime = $root.google.protobuf.Timestamp.toObject(message.verifyTime, options); - if (message.error != null && message.hasOwnProperty("error")) - object.error = $root.google.rpc.Status.toObject(message.error, options); - if (message.traces && message.traces.length) { - object.traces = []; - for (var j = 0; j < message.traces.length; ++j) - object.traces[j] = $root.google.cloud.networkmanagement.v1beta1.Trace.toObject(message.traces[j], options); + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + object.ipAddress = message.ipAddress; + if (message.port != null && message.hasOwnProperty("port")) + object.port = message.port; + if (message.instance != null && message.hasOwnProperty("instance")) + object.instance = message.instance; + if (message.network != null && message.hasOwnProperty("network")) + object.network = message.network; + if (message.networkType != null && message.hasOwnProperty("networkType")) + object.networkType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType[message.networkType] === undefined ? message.networkType : $root.google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType[message.networkType] : message.networkType; + if (message.projectId != null && message.hasOwnProperty("projectId")) + object.projectId = message.projectId; + if (message.gkeMasterCluster != null && message.hasOwnProperty("gkeMasterCluster")) + object.gkeMasterCluster = message.gkeMasterCluster; + if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) + object.cloudSqlInstance = message.cloudSqlInstance; + if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) + object.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.toObject(message.cloudFunction, options); + if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) + object.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.toObject(message.appEngineVersion, options); + if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) + object.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.toObject(message.cloudRunRevision, options); + if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) + object.forwardingRule = message.forwardingRule; + if (message.forwardingRuleTarget != null && message.hasOwnProperty("forwardingRuleTarget")) { + object.forwardingRuleTarget = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget[message.forwardingRuleTarget] === undefined ? message.forwardingRuleTarget : $root.google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget[message.forwardingRuleTarget] : message.forwardingRuleTarget; + if (options.oneofs) + object._forwardingRuleTarget = "forwardingRuleTarget"; + } + if (message.loadBalancerId != null && message.hasOwnProperty("loadBalancerId")) { + object.loadBalancerId = message.loadBalancerId; + if (options.oneofs) + object._loadBalancerId = "loadBalancerId"; + } + if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) { + object.loadBalancerType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerType[message.loadBalancerType] === undefined ? message.loadBalancerType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerType[message.loadBalancerType] : message.loadBalancerType; + if (options.oneofs) + object._loadBalancerType = "loadBalancerType"; } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) + object.redisInstance = message.redisInstance; + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) + object.redisCluster = message.redisCluster; return object; }; /** - * Converts this ReachabilityDetails to JSON. + * Converts this Endpoint to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @instance * @returns {Object.} JSON object */ - ReachabilityDetails.prototype.toJSON = function toJSON() { + Endpoint.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ReachabilityDetails + * Gets the default type url for Endpoint * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ReachabilityDetails.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Endpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ReachabilityDetails"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint"; }; /** - * Result enum. - * @name google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result + * NetworkType enum. + * @name google.cloud.networkmanagement.v1beta1.Endpoint.NetworkType * @enum {number} - * @property {number} RESULT_UNSPECIFIED=0 RESULT_UNSPECIFIED value - * @property {number} REACHABLE=1 REACHABLE value - * @property {number} UNREACHABLE=2 UNREACHABLE value - * @property {number} AMBIGUOUS=4 AMBIGUOUS value - * @property {number} UNDETERMINED=5 UNDETERMINED value + * @property {number} NETWORK_TYPE_UNSPECIFIED=0 NETWORK_TYPE_UNSPECIFIED value + * @property {number} GCP_NETWORK=1 GCP_NETWORK value + * @property {number} NON_GCP_NETWORK=2 NON_GCP_NETWORK value */ - ReachabilityDetails.Result = (function() { + Endpoint.NetworkType = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "RESULT_UNSPECIFIED"] = 0; - values[valuesById[1] = "REACHABLE"] = 1; - values[valuesById[2] = "UNREACHABLE"] = 2; - values[valuesById[4] = "AMBIGUOUS"] = 4; - values[valuesById[5] = "UNDETERMINED"] = 5; + values[valuesById[0] = "NETWORK_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "GCP_NETWORK"] = 1; + values[valuesById[2] = "NON_GCP_NETWORK"] = 2; return values; })(); - return ReachabilityDetails; - })(); - - v1beta1.LatencyPercentile = (function() { - - /** - * Properties of a LatencyPercentile. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ILatencyPercentile - * @property {number|null} [percent] LatencyPercentile percent - * @property {number|Long|null} [latencyMicros] LatencyPercentile latencyMicros - */ - /** - * Constructs a new LatencyPercentile. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a LatencyPercentile. - * @implements ILatencyPercentile - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile=} [properties] Properties to set + * ForwardingRuleTarget enum. + * @name google.cloud.networkmanagement.v1beta1.Endpoint.ForwardingRuleTarget + * @enum {number} + * @property {number} FORWARDING_RULE_TARGET_UNSPECIFIED=0 FORWARDING_RULE_TARGET_UNSPECIFIED value + * @property {number} INSTANCE=1 INSTANCE value + * @property {number} LOAD_BALANCER=2 LOAD_BALANCER value + * @property {number} VPN_GATEWAY=3 VPN_GATEWAY value + * @property {number} PSC=4 PSC value */ - function LatencyPercentile(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + Endpoint.ForwardingRuleTarget = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "FORWARDING_RULE_TARGET_UNSPECIFIED"] = 0; + values[valuesById[1] = "INSTANCE"] = 1; + values[valuesById[2] = "LOAD_BALANCER"] = 2; + values[valuesById[3] = "VPN_GATEWAY"] = 3; + values[valuesById[4] = "PSC"] = 4; + return values; + })(); - /** - * LatencyPercentile percent. - * @member {number} percent - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @instance - */ - LatencyPercentile.prototype.percent = 0; + Endpoint.CloudFunctionEndpoint = (function() { - /** - * LatencyPercentile latencyMicros. - * @member {number|Long} latencyMicros - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @instance - */ - LatencyPercentile.prototype.latencyMicros = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + /** + * Properties of a CloudFunctionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @interface ICloudFunctionEndpoint + * @property {string|null} [uri] CloudFunctionEndpoint uri + */ - /** - * Creates a new LatencyPercentile instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile instance - */ - LatencyPercentile.create = function create(properties) { - return new LatencyPercentile(properties); - }; + /** + * Constructs a new CloudFunctionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @classdesc Represents a CloudFunctionEndpoint. + * @implements ICloudFunctionEndpoint + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint=} [properties] Properties to set + */ + function CloudFunctionEndpoint(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified LatencyPercentile message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile} message LatencyPercentile message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LatencyPercentile.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.percent != null && Object.hasOwnProperty.call(message, "percent")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.percent); - if (message.latencyMicros != null && Object.hasOwnProperty.call(message, "latencyMicros")) - writer.uint32(/* id 2, wireType 0 =*/16).int64(message.latencyMicros); - return writer; - }; + /** + * CloudFunctionEndpoint uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @instance + */ + CloudFunctionEndpoint.prototype.uri = ""; - /** - * Encodes the specified LatencyPercentile message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile} message LatencyPercentile message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LatencyPercentile.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Creates a new CloudFunctionEndpoint instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint instance + */ + CloudFunctionEndpoint.create = function create(properties) { + return new CloudFunctionEndpoint(properties); + }; - /** - * Decodes a LatencyPercentile message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LatencyPercentile.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.percent = reader.int32(); - break; - } - case 2: { - message.latencyMicros = reader.int64(); + /** + * Encodes the specified CloudFunctionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint} message CloudFunctionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudFunctionEndpoint.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); + return writer; + }; + + /** + * Encodes the specified CloudFunctionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudFunctionEndpoint} message CloudFunctionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudFunctionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a CloudFunctionEndpoint message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CloudFunctionEndpoint.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.uri = reader.string(); + break; + } + default: + reader.skipType(tag & 7); break; } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; - /** - * Decodes a LatencyPercentile message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LatencyPercentile.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes a CloudFunctionEndpoint message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CloudFunctionEndpoint.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Verifies a LatencyPercentile message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - LatencyPercentile.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.percent != null && message.hasOwnProperty("percent")) - if (!$util.isInteger(message.percent)) - return "percent: integer expected"; - if (message.latencyMicros != null && message.hasOwnProperty("latencyMicros")) - if (!$util.isInteger(message.latencyMicros) && !(message.latencyMicros && $util.isInteger(message.latencyMicros.low) && $util.isInteger(message.latencyMicros.high))) - return "latencyMicros: integer|Long expected"; - return null; - }; + /** + * Verifies a CloudFunctionEndpoint message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CloudFunctionEndpoint.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + return null; + }; - /** - * Creates a LatencyPercentile message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile - */ - LatencyPercentile.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile(); - if (object.percent != null) - message.percent = object.percent | 0; - if (object.latencyMicros != null) - if ($util.Long) - (message.latencyMicros = $util.Long.fromValue(object.latencyMicros)).unsigned = false; - else if (typeof object.latencyMicros === "string") - message.latencyMicros = parseInt(object.latencyMicros, 10); - else if (typeof object.latencyMicros === "number") - message.latencyMicros = object.latencyMicros; - else if (typeof object.latencyMicros === "object") - message.latencyMicros = new $util.LongBits(object.latencyMicros.low >>> 0, object.latencyMicros.high >>> 0).toNumber(); - return message; - }; + /** + * Creates a CloudFunctionEndpoint message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} CloudFunctionEndpoint + */ + CloudFunctionEndpoint.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint(); + if (object.uri != null) + message.uri = String(object.uri); + return message; + }; - /** - * Creates a plain object from a LatencyPercentile message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {google.cloud.networkmanagement.v1beta1.LatencyPercentile} message LatencyPercentile - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - LatencyPercentile.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.percent = 0; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.latencyMicros = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.latencyMicros = options.longs === String ? "0" : 0; - } - if (message.percent != null && message.hasOwnProperty("percent")) - object.percent = message.percent; - if (message.latencyMicros != null && message.hasOwnProperty("latencyMicros")) - if (typeof message.latencyMicros === "number") - object.latencyMicros = options.longs === String ? String(message.latencyMicros) : message.latencyMicros; - else - object.latencyMicros = options.longs === String ? $util.Long.prototype.toString.call(message.latencyMicros) : options.longs === Number ? new $util.LongBits(message.latencyMicros.low >>> 0, message.latencyMicros.high >>> 0).toNumber() : message.latencyMicros; - return object; - }; + /** + * Creates a plain object from a CloudFunctionEndpoint message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint} message CloudFunctionEndpoint + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CloudFunctionEndpoint.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.uri = ""; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + return object; + }; - /** - * Converts this LatencyPercentile to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @instance - * @returns {Object.} JSON object - */ - LatencyPercentile.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Converts this CloudFunctionEndpoint to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @instance + * @returns {Object.} JSON object + */ + CloudFunctionEndpoint.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Gets the default type url for LatencyPercentile - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - LatencyPercentile.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LatencyPercentile"; - }; + /** + * Gets the default type url for CloudFunctionEndpoint + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CloudFunctionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.CloudFunctionEndpoint"; + }; - return LatencyPercentile; - })(); + return CloudFunctionEndpoint; + })(); - v1beta1.LatencyDistribution = (function() { + Endpoint.AppEngineVersionEndpoint = (function() { - /** - * Properties of a LatencyDistribution. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ILatencyDistribution - * @property {Array.|null} [latencyPercentiles] LatencyDistribution latencyPercentiles - */ + /** + * Properties of an AppEngineVersionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @interface IAppEngineVersionEndpoint + * @property {string|null} [uri] AppEngineVersionEndpoint uri + */ - /** - * Constructs a new LatencyDistribution. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a LatencyDistribution. - * @implements ILatencyDistribution - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution=} [properties] Properties to set - */ - function LatencyDistribution(properties) { - this.latencyPercentiles = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Constructs a new AppEngineVersionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @classdesc Represents an AppEngineVersionEndpoint. + * @implements IAppEngineVersionEndpoint + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint=} [properties] Properties to set + */ + function AppEngineVersionEndpoint(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * LatencyDistribution latencyPercentiles. - * @member {Array.} latencyPercentiles - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @instance - */ - LatencyDistribution.prototype.latencyPercentiles = $util.emptyArray; + /** + * AppEngineVersionEndpoint uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @instance + */ + AppEngineVersionEndpoint.prototype.uri = ""; - /** - * Creates a new LatencyDistribution instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution instance - */ - LatencyDistribution.create = function create(properties) { - return new LatencyDistribution(properties); - }; + /** + * Creates a new AppEngineVersionEndpoint instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint instance + */ + AppEngineVersionEndpoint.create = function create(properties) { + return new AppEngineVersionEndpoint(properties); + }; - /** - * Encodes the specified LatencyDistribution message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution} message LatencyDistribution message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LatencyDistribution.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.latencyPercentiles != null && message.latencyPercentiles.length) - for (var i = 0; i < message.latencyPercentiles.length; ++i) - $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.encode(message.latencyPercentiles[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - return writer; - }; + /** + * Encodes the specified AppEngineVersionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint} message AppEngineVersionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AppEngineVersionEndpoint.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); + return writer; + }; - /** - * Encodes the specified LatencyDistribution message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution} message LatencyDistribution message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LatencyDistribution.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified AppEngineVersionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.IAppEngineVersionEndpoint} message AppEngineVersionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AppEngineVersionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a LatencyDistribution message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LatencyDistribution.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.latencyPercentiles && message.latencyPercentiles.length)) - message.latencyPercentiles = []; - message.latencyPercentiles.push($root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.decode(reader, reader.uint32())); + /** + * Decodes an AppEngineVersionEndpoint message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AppEngineVersionEndpoint.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.uri = reader.string(); + break; + } + default: + reader.skipType(tag & 7); break; } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; - /** - * Decodes a LatencyDistribution message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LatencyDistribution.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes an AppEngineVersionEndpoint message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AppEngineVersionEndpoint.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Verifies a LatencyDistribution message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - LatencyDistribution.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.latencyPercentiles != null && message.hasOwnProperty("latencyPercentiles")) { - if (!Array.isArray(message.latencyPercentiles)) - return "latencyPercentiles: array expected"; - for (var i = 0; i < message.latencyPercentiles.length; ++i) { - var error = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify(message.latencyPercentiles[i]); - if (error) - return "latencyPercentiles." + error; - } - } - return null; - }; + /** + * Verifies an AppEngineVersionEndpoint message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + AppEngineVersionEndpoint.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + return null; + }; - /** - * Creates a LatencyDistribution message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution - */ - LatencyDistribution.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution(); - if (object.latencyPercentiles) { - if (!Array.isArray(object.latencyPercentiles)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.LatencyDistribution.latencyPercentiles: array expected"); - message.latencyPercentiles = []; - for (var i = 0; i < object.latencyPercentiles.length; ++i) { - if (typeof object.latencyPercentiles[i] !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.LatencyDistribution.latencyPercentiles: object expected"); - message.latencyPercentiles[i] = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.fromObject(object.latencyPercentiles[i]); - } - } - return message; - }; + /** + * Creates an AppEngineVersionEndpoint message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} AppEngineVersionEndpoint + */ + AppEngineVersionEndpoint.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint(); + if (object.uri != null) + message.uri = String(object.uri); + return message; + }; - /** - * Creates a plain object from a LatencyDistribution message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {google.cloud.networkmanagement.v1beta1.LatencyDistribution} message LatencyDistribution - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - LatencyDistribution.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.latencyPercentiles = []; - if (message.latencyPercentiles && message.latencyPercentiles.length) { - object.latencyPercentiles = []; - for (var j = 0; j < message.latencyPercentiles.length; ++j) - object.latencyPercentiles[j] = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.toObject(message.latencyPercentiles[j], options); - } - return object; - }; + /** + * Creates a plain object from an AppEngineVersionEndpoint message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint} message AppEngineVersionEndpoint + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + AppEngineVersionEndpoint.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.uri = ""; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + return object; + }; - /** - * Converts this LatencyDistribution to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @instance - * @returns {Object.} JSON object - */ - LatencyDistribution.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Converts this AppEngineVersionEndpoint to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @instance + * @returns {Object.} JSON object + */ + AppEngineVersionEndpoint.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Gets the default type url for LatencyDistribution - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - LatencyDistribution.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LatencyDistribution"; - }; + /** + * Gets the default type url for AppEngineVersionEndpoint + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + AppEngineVersionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.AppEngineVersionEndpoint"; + }; - return LatencyDistribution; - })(); + return AppEngineVersionEndpoint; + })(); - v1beta1.ProbingDetails = (function() { + Endpoint.CloudRunRevisionEndpoint = (function() { + + /** + * Properties of a CloudRunRevisionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @interface ICloudRunRevisionEndpoint + * @property {string|null} [uri] CloudRunRevisionEndpoint uri + */ + + /** + * Constructs a new CloudRunRevisionEndpoint. + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint + * @classdesc Represents a CloudRunRevisionEndpoint. + * @implements ICloudRunRevisionEndpoint + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint=} [properties] Properties to set + */ + function CloudRunRevisionEndpoint(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * CloudRunRevisionEndpoint uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @instance + */ + CloudRunRevisionEndpoint.prototype.uri = ""; + + /** + * Creates a new CloudRunRevisionEndpoint instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint instance + */ + CloudRunRevisionEndpoint.create = function create(properties) { + return new CloudRunRevisionEndpoint(properties); + }; + + /** + * Encodes the specified CloudRunRevisionEndpoint message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint} message CloudRunRevisionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudRunRevisionEndpoint.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.uri); + return writer; + }; + + /** + * Encodes the specified CloudRunRevisionEndpoint message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.ICloudRunRevisionEndpoint} message CloudRunRevisionEndpoint message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudRunRevisionEndpoint.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a CloudRunRevisionEndpoint message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CloudRunRevisionEndpoint.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.uri = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a CloudRunRevisionEndpoint message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CloudRunRevisionEndpoint.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a CloudRunRevisionEndpoint message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CloudRunRevisionEndpoint.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + return null; + }; + + /** + * Creates a CloudRunRevisionEndpoint message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} CloudRunRevisionEndpoint + */ + CloudRunRevisionEndpoint.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint(); + if (object.uri != null) + message.uri = String(object.uri); + return message; + }; + + /** + * Creates a plain object from a CloudRunRevisionEndpoint message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint} message CloudRunRevisionEndpoint + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CloudRunRevisionEndpoint.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.uri = ""; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + return object; + }; + + /** + * Converts this CloudRunRevisionEndpoint to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @instance + * @returns {Object.} JSON object + */ + CloudRunRevisionEndpoint.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for CloudRunRevisionEndpoint + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CloudRunRevisionEndpoint.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Endpoint.CloudRunRevisionEndpoint"; + }; + + return CloudRunRevisionEndpoint; + })(); + + return Endpoint; + })(); + + v1beta1.ReachabilityDetails = (function() { /** - * Properties of a ProbingDetails. + * Properties of a ReachabilityDetails. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IProbingDetails - * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult|null} [result] ProbingDetails result - * @property {google.protobuf.ITimestamp|null} [verifyTime] ProbingDetails verifyTime - * @property {google.rpc.IStatus|null} [error] ProbingDetails error - * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause|null} [abortCause] ProbingDetails abortCause - * @property {number|null} [sentProbeCount] ProbingDetails sentProbeCount - * @property {number|null} [successfulProbeCount] ProbingDetails successfulProbeCount - * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpointInfo] ProbingDetails endpointInfo - * @property {google.cloud.networkmanagement.v1beta1.ILatencyDistribution|null} [probingLatency] ProbingDetails probingLatency - * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation|null} [destinationEgressLocation] ProbingDetails destinationEgressLocation + * @interface IReachabilityDetails + * @property {google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result|null} [result] ReachabilityDetails result + * @property {google.protobuf.ITimestamp|null} [verifyTime] ReachabilityDetails verifyTime + * @property {google.rpc.IStatus|null} [error] ReachabilityDetails error + * @property {Array.|null} [traces] ReachabilityDetails traces */ /** - * Constructs a new ProbingDetails. + * Constructs a new ReachabilityDetails. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a ProbingDetails. - * @implements IProbingDetails + * @classdesc Represents a ReachabilityDetails. + * @implements IReachabilityDetails * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails=} [properties] Properties to set */ - function ProbingDetails(properties) { + function ReachabilityDetails(properties) { + this.traces = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20127,99 +20904,59 @@ } /** - * ProbingDetails result. - * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult} result - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * ReachabilityDetails result. + * @member {google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result} result + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @instance */ - ProbingDetails.prototype.result = 0; + ReachabilityDetails.prototype.result = 0; /** - * ProbingDetails verifyTime. + * ReachabilityDetails verifyTime. * @member {google.protobuf.ITimestamp|null|undefined} verifyTime - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @instance */ - ProbingDetails.prototype.verifyTime = null; + ReachabilityDetails.prototype.verifyTime = null; /** - * ProbingDetails error. + * ReachabilityDetails error. * @member {google.rpc.IStatus|null|undefined} error - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @instance */ - ProbingDetails.prototype.error = null; + ReachabilityDetails.prototype.error = null; /** - * ProbingDetails abortCause. - * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause} abortCause - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @instance - */ - ProbingDetails.prototype.abortCause = 0; - - /** - * ProbingDetails sentProbeCount. - * @member {number} sentProbeCount - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @instance - */ - ProbingDetails.prototype.sentProbeCount = 0; - - /** - * ProbingDetails successfulProbeCount. - * @member {number} successfulProbeCount - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @instance - */ - ProbingDetails.prototype.successfulProbeCount = 0; - - /** - * ProbingDetails endpointInfo. - * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpointInfo - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @instance - */ - ProbingDetails.prototype.endpointInfo = null; - - /** - * ProbingDetails probingLatency. - * @member {google.cloud.networkmanagement.v1beta1.ILatencyDistribution|null|undefined} probingLatency - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @instance - */ - ProbingDetails.prototype.probingLatency = null; - - /** - * ProbingDetails destinationEgressLocation. - * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation|null|undefined} destinationEgressLocation - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * ReachabilityDetails traces. + * @member {Array.} traces + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @instance */ - ProbingDetails.prototype.destinationEgressLocation = null; + ReachabilityDetails.prototype.traces = $util.emptyArray; /** - * Creates a new ProbingDetails instance using the specified properties. + * Creates a new ReachabilityDetails instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static - * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails instance + * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails instance */ - ProbingDetails.create = function create(properties) { - return new ProbingDetails(properties); + ReachabilityDetails.create = function create(properties) { + return new ReachabilityDetails(properties); }; /** - * Encodes the specified ProbingDetails message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.verify|verify} messages. + * Encodes the specified ReachabilityDetails message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static - * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails} message ProbingDetails message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails} message ReachabilityDetails message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ProbingDetails.encode = function encode(message, writer) { + ReachabilityDetails.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.result != null && Object.hasOwnProperty.call(message, "result")) @@ -20228,49 +20965,40 @@ $root.google.protobuf.Timestamp.encode(message.verifyTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); if (message.error != null && Object.hasOwnProperty.call(message, "error")) $root.google.rpc.Status.encode(message.error, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.abortCause != null && Object.hasOwnProperty.call(message, "abortCause")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.abortCause); - if (message.sentProbeCount != null && Object.hasOwnProperty.call(message, "sentProbeCount")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.sentProbeCount); - if (message.successfulProbeCount != null && Object.hasOwnProperty.call(message, "successfulProbeCount")) - writer.uint32(/* id 6, wireType 0 =*/48).int32(message.successfulProbeCount); - if (message.endpointInfo != null && Object.hasOwnProperty.call(message, "endpointInfo")) - $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpointInfo, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - if (message.probingLatency != null && Object.hasOwnProperty.call(message, "probingLatency")) - $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.encode(message.probingLatency, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.destinationEgressLocation != null && Object.hasOwnProperty.call(message, "destinationEgressLocation")) - $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.encode(message.destinationEgressLocation, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + if (message.traces != null && message.traces.length) + for (var i = 0; i < message.traces.length; ++i) + $root.google.cloud.networkmanagement.v1beta1.Trace.encode(message.traces[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); return writer; }; /** - * Encodes the specified ProbingDetails message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.verify|verify} messages. + * Encodes the specified ReachabilityDetails message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static - * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails} message ProbingDetails message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IReachabilityDetails} message ReachabilityDetails message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ProbingDetails.encodeDelimited = function encodeDelimited(message, writer) { + ReachabilityDetails.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ProbingDetails message from the specified reader or buffer. + * Decodes a ReachabilityDetails message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails + * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ProbingDetails.decode = function decode(reader, length) { + ReachabilityDetails.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -20286,28 +21014,10 @@ message.error = $root.google.rpc.Status.decode(reader, reader.uint32()); break; } - case 4: { - message.abortCause = reader.int32(); - break; - } case 5: { - message.sentProbeCount = reader.int32(); - break; - } - case 6: { - message.successfulProbeCount = reader.int32(); - break; - } - case 7: { - message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); - break; - } - case 8: { - message.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.decode(reader, reader.uint32()); - break; - } - case 9: { - message.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.decode(reader, reader.uint32()); + if (!(message.traces && message.traces.length)) + message.traces = []; + message.traces.push($root.google.cloud.networkmanagement.v1beta1.Trace.decode(reader, reader.uint32())); break; } default: @@ -20319,30 +21029,30 @@ }; /** - * Decodes a ProbingDetails message from the specified reader or buffer, length delimited. + * Decodes a ReachabilityDetails message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails + * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ProbingDetails.decodeDelimited = function decodeDelimited(reader) { + ReachabilityDetails.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ProbingDetails message. + * Verifies a ReachabilityDetails message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ProbingDetails.verify = function verify(message) { + ReachabilityDetails.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.result != null && message.hasOwnProperty("result")) @@ -20352,8 +21062,8 @@ case 0: case 1: case 2: - case 3: case 4: + case 5: break; } if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) { @@ -20366,51 +21076,30 @@ if (error) return "error." + error; } - if (message.abortCause != null && message.hasOwnProperty("abortCause")) - switch (message.abortCause) { - default: - return "abortCause: enum value expected"; - case 0: - case 1: - case 2: - break; + if (message.traces != null && message.hasOwnProperty("traces")) { + if (!Array.isArray(message.traces)) + return "traces: array expected"; + for (var i = 0; i < message.traces.length; ++i) { + var error = $root.google.cloud.networkmanagement.v1beta1.Trace.verify(message.traces[i]); + if (error) + return "traces." + error; } - if (message.sentProbeCount != null && message.hasOwnProperty("sentProbeCount")) - if (!$util.isInteger(message.sentProbeCount)) - return "sentProbeCount: integer expected"; - if (message.successfulProbeCount != null && message.hasOwnProperty("successfulProbeCount")) - if (!$util.isInteger(message.successfulProbeCount)) - return "successfulProbeCount: integer expected"; - if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) { - var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpointInfo); - if (error) - return "endpointInfo." + error; - } - if (message.probingLatency != null && message.hasOwnProperty("probingLatency")) { - var error = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify(message.probingLatency); - if (error) - return "probingLatency." + error; - } - if (message.destinationEgressLocation != null && message.hasOwnProperty("destinationEgressLocation")) { - var error = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify(message.destinationEgressLocation); - if (error) - return "destinationEgressLocation." + error; } return null; }; /** - * Creates a ProbingDetails message from a plain object. Also converts values to their respective internal types. + * Creates a ReachabilityDetails message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails + * @returns {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} ReachabilityDetails */ - ProbingDetails.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ProbingDetails) + ReachabilityDetails.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails(); + var message = new $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails(); switch (object.result) { default: if (typeof object.result === "number") { @@ -20418,7 +21107,7 @@ break; } break; - case "PROBING_RESULT_UNSPECIFIED": + case "RESULT_UNSPECIFIED": case 0: message.result = 0; break; @@ -20430,401 +21119,381 @@ case 2: message.result = 2; break; - case "REACHABILITY_INCONSISTENT": - case 3: - message.result = 3; - break; - case "UNDETERMINED": + case "AMBIGUOUS": case 4: message.result = 4; break; + case "UNDETERMINED": + case 5: + message.result = 5; + break; } if (object.verifyTime != null) { if (typeof object.verifyTime !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.verifyTime: object expected"); + throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.verifyTime: object expected"); message.verifyTime = $root.google.protobuf.Timestamp.fromObject(object.verifyTime); } if (object.error != null) { if (typeof object.error !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.error: object expected"); + throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.error: object expected"); message.error = $root.google.rpc.Status.fromObject(object.error); } - switch (object.abortCause) { - default: - if (typeof object.abortCause === "number") { - message.abortCause = object.abortCause; - break; + if (object.traces) { + if (!Array.isArray(object.traces)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.traces: array expected"); + message.traces = []; + for (var i = 0; i < object.traces.length; ++i) { + if (typeof object.traces[i] !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ReachabilityDetails.traces: object expected"); + message.traces[i] = $root.google.cloud.networkmanagement.v1beta1.Trace.fromObject(object.traces[i]); } - break; - case "PROBING_ABORT_CAUSE_UNSPECIFIED": - case 0: - message.abortCause = 0; - break; - case "PERMISSION_DENIED": - case 1: - message.abortCause = 1; - break; - case "NO_SOURCE_LOCATION": - case 2: - message.abortCause = 2; - break; - } - if (object.sentProbeCount != null) - message.sentProbeCount = object.sentProbeCount | 0; - if (object.successfulProbeCount != null) - message.successfulProbeCount = object.successfulProbeCount | 0; - if (object.endpointInfo != null) { - if (typeof object.endpointInfo !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.endpointInfo: object expected"); - message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpointInfo); - } - if (object.probingLatency != null) { - if (typeof object.probingLatency !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.probingLatency: object expected"); - message.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.fromObject(object.probingLatency); - } - if (object.destinationEgressLocation != null) { - if (typeof object.destinationEgressLocation !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.destinationEgressLocation: object expected"); - message.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.fromObject(object.destinationEgressLocation); } return message; }; /** - * Creates a plain object from a ProbingDetails message. Also converts values to other types if specified. + * Creates a plain object from a ReachabilityDetails message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails} message ProbingDetails + * @param {google.cloud.networkmanagement.v1beta1.ReachabilityDetails} message ReachabilityDetails * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ProbingDetails.toObject = function toObject(message, options) { + ReachabilityDetails.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.result = options.enums === String ? "PROBING_RESULT_UNSPECIFIED" : 0; + if (options.arrays || options.defaults) + object.traces = []; + if (options.defaults) { + object.result = options.enums === String ? "RESULT_UNSPECIFIED" : 0; object.verifyTime = null; object.error = null; - object.abortCause = options.enums === String ? "PROBING_ABORT_CAUSE_UNSPECIFIED" : 0; - object.sentProbeCount = 0; - object.successfulProbeCount = 0; - object.endpointInfo = null; - object.probingLatency = null; - object.destinationEgressLocation = null; } if (message.result != null && message.hasOwnProperty("result")) - object.result = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult[message.result] === undefined ? message.result : $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult[message.result] : message.result; + object.result = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result[message.result] === undefined ? message.result : $root.google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result[message.result] : message.result; if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) object.verifyTime = $root.google.protobuf.Timestamp.toObject(message.verifyTime, options); if (message.error != null && message.hasOwnProperty("error")) object.error = $root.google.rpc.Status.toObject(message.error, options); - if (message.abortCause != null && message.hasOwnProperty("abortCause")) - object.abortCause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause[message.abortCause] === undefined ? message.abortCause : $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause[message.abortCause] : message.abortCause; - if (message.sentProbeCount != null && message.hasOwnProperty("sentProbeCount")) - object.sentProbeCount = message.sentProbeCount; - if (message.successfulProbeCount != null && message.hasOwnProperty("successfulProbeCount")) - object.successfulProbeCount = message.successfulProbeCount; - if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) - object.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpointInfo, options); - if (message.probingLatency != null && message.hasOwnProperty("probingLatency")) - object.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.toObject(message.probingLatency, options); - if (message.destinationEgressLocation != null && message.hasOwnProperty("destinationEgressLocation")) - object.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.toObject(message.destinationEgressLocation, options); + if (message.traces && message.traces.length) { + object.traces = []; + for (var j = 0; j < message.traces.length; ++j) + object.traces[j] = $root.google.cloud.networkmanagement.v1beta1.Trace.toObject(message.traces[j], options); + } return object; }; /** - * Converts this ProbingDetails to JSON. + * Converts this ReachabilityDetails to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @instance * @returns {Object.} JSON object */ - ProbingDetails.prototype.toJSON = function toJSON() { + ReachabilityDetails.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ProbingDetails + * Gets the default type url for ReachabilityDetails * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @memberof google.cloud.networkmanagement.v1beta1.ReachabilityDetails * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ProbingDetails.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ReachabilityDetails.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ProbingDetails"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ReachabilityDetails"; }; /** - * ProbingResult enum. - * @name google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult + * Result enum. + * @name google.cloud.networkmanagement.v1beta1.ReachabilityDetails.Result * @enum {number} - * @property {number} PROBING_RESULT_UNSPECIFIED=0 PROBING_RESULT_UNSPECIFIED value + * @property {number} RESULT_UNSPECIFIED=0 RESULT_UNSPECIFIED value * @property {number} REACHABLE=1 REACHABLE value * @property {number} UNREACHABLE=2 UNREACHABLE value - * @property {number} REACHABILITY_INCONSISTENT=3 REACHABILITY_INCONSISTENT value - * @property {number} UNDETERMINED=4 UNDETERMINED value + * @property {number} AMBIGUOUS=4 AMBIGUOUS value + * @property {number} UNDETERMINED=5 UNDETERMINED value */ - ProbingDetails.ProbingResult = (function() { + ReachabilityDetails.Result = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "PROBING_RESULT_UNSPECIFIED"] = 0; + values[valuesById[0] = "RESULT_UNSPECIFIED"] = 0; values[valuesById[1] = "REACHABLE"] = 1; values[valuesById[2] = "UNREACHABLE"] = 2; - values[valuesById[3] = "REACHABILITY_INCONSISTENT"] = 3; - values[valuesById[4] = "UNDETERMINED"] = 4; + values[valuesById[4] = "AMBIGUOUS"] = 4; + values[valuesById[5] = "UNDETERMINED"] = 5; return values; })(); + return ReachabilityDetails; + })(); + + v1beta1.LatencyPercentile = (function() { + /** - * ProbingAbortCause enum. - * @name google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause - * @enum {number} - * @property {number} PROBING_ABORT_CAUSE_UNSPECIFIED=0 PROBING_ABORT_CAUSE_UNSPECIFIED value - * @property {number} PERMISSION_DENIED=1 PERMISSION_DENIED value - * @property {number} NO_SOURCE_LOCATION=2 NO_SOURCE_LOCATION value + * Properties of a LatencyPercentile. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface ILatencyPercentile + * @property {number|null} [percent] LatencyPercentile percent + * @property {number|Long|null} [latencyMicros] LatencyPercentile latencyMicros */ - ProbingDetails.ProbingAbortCause = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "PROBING_ABORT_CAUSE_UNSPECIFIED"] = 0; - values[valuesById[1] = "PERMISSION_DENIED"] = 1; - values[valuesById[2] = "NO_SOURCE_LOCATION"] = 2; - return values; - })(); - ProbingDetails.EdgeLocation = (function() { + /** + * Constructs a new LatencyPercentile. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a LatencyPercentile. + * @implements ILatencyPercentile + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile=} [properties] Properties to set + */ + function LatencyPercentile(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Properties of an EdgeLocation. - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @interface IEdgeLocation - * @property {string|null} [metropolitanArea] EdgeLocation metropolitanArea - */ + /** + * LatencyPercentile percent. + * @member {number} percent + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @instance + */ + LatencyPercentile.prototype.percent = 0; - /** - * Constructs a new EdgeLocation. - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails - * @classdesc Represents an EdgeLocation. - * @implements IEdgeLocation - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation=} [properties] Properties to set - */ - function EdgeLocation(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * LatencyPercentile latencyMicros. + * @member {number|Long} latencyMicros + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @instance + */ + LatencyPercentile.prototype.latencyMicros = $util.Long ? $util.Long.fromBits(0,0,false) : 0; - /** - * EdgeLocation metropolitanArea. - * @member {string} metropolitanArea - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @instance - */ - EdgeLocation.prototype.metropolitanArea = ""; + /** + * Creates a new LatencyPercentile instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile instance + */ + LatencyPercentile.create = function create(properties) { + return new LatencyPercentile(properties); + }; - /** - * Creates a new EdgeLocation instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation instance - */ - EdgeLocation.create = function create(properties) { - return new EdgeLocation(properties); - }; + /** + * Encodes the specified LatencyPercentile message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile} message LatencyPercentile message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LatencyPercentile.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.percent != null && Object.hasOwnProperty.call(message, "percent")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.percent); + if (message.latencyMicros != null && Object.hasOwnProperty.call(message, "latencyMicros")) + writer.uint32(/* id 2, wireType 0 =*/16).int64(message.latencyMicros); + return writer; + }; - /** - * Encodes the specified EdgeLocation message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation} message EdgeLocation message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EdgeLocation.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.metropolitanArea != null && Object.hasOwnProperty.call(message, "metropolitanArea")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.metropolitanArea); - return writer; - }; + /** + * Encodes the specified LatencyPercentile message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {google.cloud.networkmanagement.v1beta1.ILatencyPercentile} message LatencyPercentile message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LatencyPercentile.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Encodes the specified EdgeLocation message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation} message EdgeLocation message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EdgeLocation.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Decodes a LatencyPercentile message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LatencyPercentile.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.percent = reader.int32(); + break; + } + case 2: { + message.latencyMicros = reader.int64(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Decodes an EdgeLocation message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EdgeLocation.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.metropolitanArea = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EdgeLocation message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EdgeLocation.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EdgeLocation message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EdgeLocation.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.metropolitanArea != null && message.hasOwnProperty("metropolitanArea")) - if (!$util.isString(message.metropolitanArea)) - return "metropolitanArea: string expected"; - return null; - }; + /** + * Decodes a LatencyPercentile message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LatencyPercentile.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates an EdgeLocation message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation - */ - EdgeLocation.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation(); - if (object.metropolitanArea != null) - message.metropolitanArea = String(object.metropolitanArea); - return message; - }; + /** + * Verifies a LatencyPercentile message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + LatencyPercentile.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.percent != null && message.hasOwnProperty("percent")) + if (!$util.isInteger(message.percent)) + return "percent: integer expected"; + if (message.latencyMicros != null && message.hasOwnProperty("latencyMicros")) + if (!$util.isInteger(message.latencyMicros) && !(message.latencyMicros && $util.isInteger(message.latencyMicros.low) && $util.isInteger(message.latencyMicros.high))) + return "latencyMicros: integer|Long expected"; + return null; + }; - /** - * Creates a plain object from an EdgeLocation message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} message EdgeLocation - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EdgeLocation.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.metropolitanArea = ""; - if (message.metropolitanArea != null && message.hasOwnProperty("metropolitanArea")) - object.metropolitanArea = message.metropolitanArea; + /** + * Creates a LatencyPercentile message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.LatencyPercentile} LatencyPercentile + */ + LatencyPercentile.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile) return object; - }; + var message = new $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile(); + if (object.percent != null) + message.percent = object.percent | 0; + if (object.latencyMicros != null) + if ($util.Long) + (message.latencyMicros = $util.Long.fromValue(object.latencyMicros)).unsigned = false; + else if (typeof object.latencyMicros === "string") + message.latencyMicros = parseInt(object.latencyMicros, 10); + else if (typeof object.latencyMicros === "number") + message.latencyMicros = object.latencyMicros; + else if (typeof object.latencyMicros === "object") + message.latencyMicros = new $util.LongBits(object.latencyMicros.low >>> 0, object.latencyMicros.high >>> 0).toNumber(); + return message; + }; - /** - * Converts this EdgeLocation to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @instance - * @returns {Object.} JSON object - */ - EdgeLocation.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Creates a plain object from a LatencyPercentile message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {google.cloud.networkmanagement.v1beta1.LatencyPercentile} message LatencyPercentile + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + LatencyPercentile.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.percent = 0; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.latencyMicros = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.latencyMicros = options.longs === String ? "0" : 0; + } + if (message.percent != null && message.hasOwnProperty("percent")) + object.percent = message.percent; + if (message.latencyMicros != null && message.hasOwnProperty("latencyMicros")) + if (typeof message.latencyMicros === "number") + object.latencyMicros = options.longs === String ? String(message.latencyMicros) : message.latencyMicros; + else + object.latencyMicros = options.longs === String ? $util.Long.prototype.toString.call(message.latencyMicros) : options.longs === Number ? new $util.LongBits(message.latencyMicros.low >>> 0, message.latencyMicros.high >>> 0).toNumber() : message.latencyMicros; + return object; + }; - /** - * Gets the default type url for EdgeLocation - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EdgeLocation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation"; - }; + /** + * Converts this LatencyPercentile to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @instance + * @returns {Object.} JSON object + */ + LatencyPercentile.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - return EdgeLocation; - })(); + /** + * Gets the default type url for LatencyPercentile + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.LatencyPercentile + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + LatencyPercentile.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LatencyPercentile"; + }; - return ProbingDetails; + return LatencyPercentile; })(); - v1beta1.Trace = (function() { + v1beta1.LatencyDistribution = (function() { /** - * Properties of a Trace. + * Properties of a LatencyDistribution. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ITrace - * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpointInfo] Trace endpointInfo - * @property {Array.|null} [steps] Trace steps - * @property {number|null} [forwardTraceId] Trace forwardTraceId + * @interface ILatencyDistribution + * @property {Array.|null} [latencyPercentiles] LatencyDistribution latencyPercentiles */ /** - * Constructs a new Trace. + * Constructs a new LatencyDistribution. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a Trace. - * @implements ITrace + * @classdesc Represents a LatencyDistribution. + * @implements ILatencyDistribution * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ITrace=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution=} [properties] Properties to set */ - function Trace(properties) { - this.steps = []; + function LatencyDistribution(properties) { + this.latencyPercentiles = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20832,106 +21501,78 @@ } /** - * Trace endpointInfo. - * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpointInfo - * @memberof google.cloud.networkmanagement.v1beta1.Trace - * @instance - */ - Trace.prototype.endpointInfo = null; - - /** - * Trace steps. - * @member {Array.} steps - * @memberof google.cloud.networkmanagement.v1beta1.Trace - * @instance - */ - Trace.prototype.steps = $util.emptyArray; - - /** - * Trace forwardTraceId. - * @member {number} forwardTraceId - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * LatencyDistribution latencyPercentiles. + * @member {Array.} latencyPercentiles + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @instance */ - Trace.prototype.forwardTraceId = 0; + LatencyDistribution.prototype.latencyPercentiles = $util.emptyArray; /** - * Creates a new Trace instance using the specified properties. + * Creates a new LatencyDistribution instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static - * @param {google.cloud.networkmanagement.v1beta1.ITrace=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace instance + * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution instance */ - Trace.create = function create(properties) { - return new Trace(properties); + LatencyDistribution.create = function create(properties) { + return new LatencyDistribution(properties); }; /** - * Encodes the specified Trace message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Trace.verify|verify} messages. + * Encodes the specified LatencyDistribution message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static - * @param {google.cloud.networkmanagement.v1beta1.ITrace} message Trace message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution} message LatencyDistribution message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Trace.encode = function encode(message, writer) { + LatencyDistribution.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.endpointInfo != null && Object.hasOwnProperty.call(message, "endpointInfo")) - $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpointInfo, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.steps != null && message.steps.length) - for (var i = 0; i < message.steps.length; ++i) - $root.google.cloud.networkmanagement.v1beta1.Step.encode(message.steps[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.forwardTraceId != null && Object.hasOwnProperty.call(message, "forwardTraceId")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.forwardTraceId); + if (message.latencyPercentiles != null && message.latencyPercentiles.length) + for (var i = 0; i < message.latencyPercentiles.length; ++i) + $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.encode(message.latencyPercentiles[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified Trace message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Trace.verify|verify} messages. + * Encodes the specified LatencyDistribution message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static - * @param {google.cloud.networkmanagement.v1beta1.ITrace} message Trace message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.ILatencyDistribution} message LatencyDistribution message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Trace.encodeDelimited = function encodeDelimited(message, writer) { + LatencyDistribution.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Trace message from the specified reader or buffer. + * Decodes a LatencyDistribution message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Trace.decode = function decode(reader, length) { + LatencyDistribution.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Trace(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); - break; - } - case 2: { - if (!(message.steps && message.steps.length)) - message.steps = []; - message.steps.push($root.google.cloud.networkmanagement.v1beta1.Step.decode(reader, reader.uint32())); - break; - } - case 4: { - message.forwardTraceId = reader.int32(); + if (!(message.latencyPercentiles && message.latencyPercentiles.length)) + message.latencyPercentiles = []; + message.latencyPercentiles.push($root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.decode(reader, reader.uint32())); break; } default: @@ -20943,189 +21584,147 @@ }; /** - * Decodes a Trace message from the specified reader or buffer, length delimited. + * Decodes a LatencyDistribution message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Trace.decodeDelimited = function decodeDelimited(reader) { + LatencyDistribution.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Trace message. + * Verifies a LatencyDistribution message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Trace.verify = function verify(message) { + LatencyDistribution.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) { - var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpointInfo); - if (error) - return "endpointInfo." + error; - } - if (message.steps != null && message.hasOwnProperty("steps")) { - if (!Array.isArray(message.steps)) - return "steps: array expected"; - for (var i = 0; i < message.steps.length; ++i) { - var error = $root.google.cloud.networkmanagement.v1beta1.Step.verify(message.steps[i]); + if (message.latencyPercentiles != null && message.hasOwnProperty("latencyPercentiles")) { + if (!Array.isArray(message.latencyPercentiles)) + return "latencyPercentiles: array expected"; + for (var i = 0; i < message.latencyPercentiles.length; ++i) { + var error = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.verify(message.latencyPercentiles[i]); if (error) - return "steps." + error; + return "latencyPercentiles." + error; } } - if (message.forwardTraceId != null && message.hasOwnProperty("forwardTraceId")) - if (!$util.isInteger(message.forwardTraceId)) - return "forwardTraceId: integer expected"; return null; }; /** - * Creates a Trace message from a plain object. Also converts values to their respective internal types. + * Creates a LatencyDistribution message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + * @returns {google.cloud.networkmanagement.v1beta1.LatencyDistribution} LatencyDistribution */ - Trace.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Trace) + LatencyDistribution.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Trace(); - if (object.endpointInfo != null) { - if (typeof object.endpointInfo !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.endpointInfo: object expected"); - message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpointInfo); - } - if (object.steps) { - if (!Array.isArray(object.steps)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.steps: array expected"); - message.steps = []; - for (var i = 0; i < object.steps.length; ++i) { - if (typeof object.steps[i] !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.steps: object expected"); - message.steps[i] = $root.google.cloud.networkmanagement.v1beta1.Step.fromObject(object.steps[i]); + var message = new $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution(); + if (object.latencyPercentiles) { + if (!Array.isArray(object.latencyPercentiles)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.LatencyDistribution.latencyPercentiles: array expected"); + message.latencyPercentiles = []; + for (var i = 0; i < object.latencyPercentiles.length; ++i) { + if (typeof object.latencyPercentiles[i] !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.LatencyDistribution.latencyPercentiles: object expected"); + message.latencyPercentiles[i] = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.fromObject(object.latencyPercentiles[i]); } } - if (object.forwardTraceId != null) - message.forwardTraceId = object.forwardTraceId | 0; return message; }; /** - * Creates a plain object from a Trace message. Also converts values to other types if specified. + * Creates a plain object from a LatencyDistribution message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static - * @param {google.cloud.networkmanagement.v1beta1.Trace} message Trace + * @param {google.cloud.networkmanagement.v1beta1.LatencyDistribution} message LatencyDistribution * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Trace.toObject = function toObject(message, options) { + LatencyDistribution.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.steps = []; - if (options.defaults) { - object.endpointInfo = null; - object.forwardTraceId = 0; - } - if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) - object.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpointInfo, options); - if (message.steps && message.steps.length) { - object.steps = []; - for (var j = 0; j < message.steps.length; ++j) - object.steps[j] = $root.google.cloud.networkmanagement.v1beta1.Step.toObject(message.steps[j], options); + object.latencyPercentiles = []; + if (message.latencyPercentiles && message.latencyPercentiles.length) { + object.latencyPercentiles = []; + for (var j = 0; j < message.latencyPercentiles.length; ++j) + object.latencyPercentiles[j] = $root.google.cloud.networkmanagement.v1beta1.LatencyPercentile.toObject(message.latencyPercentiles[j], options); } - if (message.forwardTraceId != null && message.hasOwnProperty("forwardTraceId")) - object.forwardTraceId = message.forwardTraceId; return object; }; /** - * Converts this Trace to JSON. + * Converts this LatencyDistribution to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @instance * @returns {Object.} JSON object */ - Trace.prototype.toJSON = function toJSON() { + LatencyDistribution.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Trace + * Gets the default type url for LatencyDistribution * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @memberof google.cloud.networkmanagement.v1beta1.LatencyDistribution * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Trace.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + LatencyDistribution.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Trace"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LatencyDistribution"; }; - return Trace; + return LatencyDistribution; })(); - v1beta1.Step = (function() { + v1beta1.ProbingDetails = (function() { /** - * Properties of a Step. + * Properties of a ProbingDetails. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IStep - * @property {string|null} [description] Step description - * @property {google.cloud.networkmanagement.v1beta1.Step.State|null} [state] Step state - * @property {boolean|null} [causesDrop] Step causesDrop - * @property {string|null} [projectId] Step projectId - * @property {google.cloud.networkmanagement.v1beta1.IInstanceInfo|null} [instance] Step instance - * @property {google.cloud.networkmanagement.v1beta1.IFirewallInfo|null} [firewall] Step firewall - * @property {google.cloud.networkmanagement.v1beta1.IRouteInfo|null} [route] Step route - * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpoint] Step endpoint - * @property {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo|null} [googleService] Step googleService - * @property {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo|null} [forwardingRule] Step forwardingRule - * @property {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo|null} [vpnGateway] Step vpnGateway - * @property {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo|null} [vpnTunnel] Step vpnTunnel - * @property {google.cloud.networkmanagement.v1beta1.IVpcConnectorInfo|null} [vpcConnector] Step vpcConnector - * @property {google.cloud.networkmanagement.v1beta1.IDeliverInfo|null} [deliver] Step deliver - * @property {google.cloud.networkmanagement.v1beta1.IForwardInfo|null} [forward] Step forward - * @property {google.cloud.networkmanagement.v1beta1.IAbortInfo|null} [abort] Step abort - * @property {google.cloud.networkmanagement.v1beta1.IDropInfo|null} [drop] Step drop - * @property {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo|null} [loadBalancer] Step loadBalancer - * @property {google.cloud.networkmanagement.v1beta1.INetworkInfo|null} [network] Step network - * @property {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo|null} [gkeMaster] Step gkeMaster - * @property {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null} [cloudSqlInstance] Step cloudSqlInstance - * @property {google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null} [cloudFunction] Step cloudFunction - * @property {google.cloud.networkmanagement.v1beta1.IAppEngineVersionInfo|null} [appEngineVersion] Step appEngineVersion - * @property {google.cloud.networkmanagement.v1beta1.ICloudRunRevisionInfo|null} [cloudRunRevision] Step cloudRunRevision - * @property {google.cloud.networkmanagement.v1beta1.INatInfo|null} [nat] Step nat - * @property {google.cloud.networkmanagement.v1beta1.IProxyConnectionInfo|null} [proxyConnection] Step proxyConnection - * @property {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackendInfo|null} [loadBalancerBackendInfo] Step loadBalancerBackendInfo - * @property {google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null} [storageBucket] Step storageBucket + * @interface IProbingDetails + * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult|null} [result] ProbingDetails result + * @property {google.protobuf.ITimestamp|null} [verifyTime] ProbingDetails verifyTime + * @property {google.rpc.IStatus|null} [error] ProbingDetails error + * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause|null} [abortCause] ProbingDetails abortCause + * @property {number|null} [sentProbeCount] ProbingDetails sentProbeCount + * @property {number|null} [successfulProbeCount] ProbingDetails successfulProbeCount + * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpointInfo] ProbingDetails endpointInfo + * @property {google.cloud.networkmanagement.v1beta1.ILatencyDistribution|null} [probingLatency] ProbingDetails probingLatency + * @property {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation|null} [destinationEgressLocation] ProbingDetails destinationEgressLocation */ /** - * Constructs a new Step. + * Constructs a new ProbingDetails. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a Step. - * @implements IStep + * @classdesc Represents a ProbingDetails. + * @implements IProbingDetails * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IStep=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails=} [properties] Properties to set */ - function Step(properties) { + function ProbingDetails(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -21133,1822 +21732,1518 @@ } /** - * Step description. - * @member {string} description - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails result. + * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult} result + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.description = ""; - - /** - * Step state. - * @member {google.cloud.networkmanagement.v1beta1.Step.State} state - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.state = 0; - - /** - * Step causesDrop. - * @member {boolean} causesDrop - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.causesDrop = false; - - /** - * Step projectId. - * @member {string} projectId - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.projectId = ""; - - /** - * Step instance. - * @member {google.cloud.networkmanagement.v1beta1.IInstanceInfo|null|undefined} instance - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.instance = null; + ProbingDetails.prototype.result = 0; /** - * Step firewall. - * @member {google.cloud.networkmanagement.v1beta1.IFirewallInfo|null|undefined} firewall - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails verifyTime. + * @member {google.protobuf.ITimestamp|null|undefined} verifyTime + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.firewall = null; + ProbingDetails.prototype.verifyTime = null; /** - * Step route. - * @member {google.cloud.networkmanagement.v1beta1.IRouteInfo|null|undefined} route - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails error. + * @member {google.rpc.IStatus|null|undefined} error + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.route = null; + ProbingDetails.prototype.error = null; /** - * Step endpoint. - * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpoint - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails abortCause. + * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause} abortCause + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.endpoint = null; + ProbingDetails.prototype.abortCause = 0; /** - * Step googleService. - * @member {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo|null|undefined} googleService - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails sentProbeCount. + * @member {number} sentProbeCount + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.googleService = null; + ProbingDetails.prototype.sentProbeCount = 0; /** - * Step forwardingRule. - * @member {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo|null|undefined} forwardingRule - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails successfulProbeCount. + * @member {number} successfulProbeCount + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.forwardingRule = null; + ProbingDetails.prototype.successfulProbeCount = 0; /** - * Step vpnGateway. - * @member {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo|null|undefined} vpnGateway - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails endpointInfo. + * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.vpnGateway = null; + ProbingDetails.prototype.endpointInfo = null; /** - * Step vpnTunnel. - * @member {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo|null|undefined} vpnTunnel - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails probingLatency. + * @member {google.cloud.networkmanagement.v1beta1.ILatencyDistribution|null|undefined} probingLatency + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.vpnTunnel = null; + ProbingDetails.prototype.probingLatency = null; /** - * Step vpcConnector. - * @member {google.cloud.networkmanagement.v1beta1.IVpcConnectorInfo|null|undefined} vpcConnector - * @memberof google.cloud.networkmanagement.v1beta1.Step + * ProbingDetails destinationEgressLocation. + * @member {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation|null|undefined} destinationEgressLocation + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance */ - Step.prototype.vpcConnector = null; + ProbingDetails.prototype.destinationEgressLocation = null; /** - * Step deliver. - * @member {google.cloud.networkmanagement.v1beta1.IDeliverInfo|null|undefined} deliver - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Creates a new ProbingDetails instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails instance */ - Step.prototype.deliver = null; + ProbingDetails.create = function create(properties) { + return new ProbingDetails(properties); + }; /** - * Step forward. - * @member {google.cloud.networkmanagement.v1beta1.IForwardInfo|null|undefined} forward - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Encodes the specified ProbingDetails message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails} message ProbingDetails message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Step.prototype.forward = null; + ProbingDetails.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.result != null && Object.hasOwnProperty.call(message, "result")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.result); + if (message.verifyTime != null && Object.hasOwnProperty.call(message, "verifyTime")) + $root.google.protobuf.Timestamp.encode(message.verifyTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.error != null && Object.hasOwnProperty.call(message, "error")) + $root.google.rpc.Status.encode(message.error, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.abortCause != null && Object.hasOwnProperty.call(message, "abortCause")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.abortCause); + if (message.sentProbeCount != null && Object.hasOwnProperty.call(message, "sentProbeCount")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.sentProbeCount); + if (message.successfulProbeCount != null && Object.hasOwnProperty.call(message, "successfulProbeCount")) + writer.uint32(/* id 6, wireType 0 =*/48).int32(message.successfulProbeCount); + if (message.endpointInfo != null && Object.hasOwnProperty.call(message, "endpointInfo")) + $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpointInfo, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.probingLatency != null && Object.hasOwnProperty.call(message, "probingLatency")) + $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.encode(message.probingLatency, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.destinationEgressLocation != null && Object.hasOwnProperty.call(message, "destinationEgressLocation")) + $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.encode(message.destinationEgressLocation, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + return writer; + }; /** - * Step abort. - * @member {google.cloud.networkmanagement.v1beta1.IAbortInfo|null|undefined} abort - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Encodes the specified ProbingDetails message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {google.cloud.networkmanagement.v1beta1.IProbingDetails} message ProbingDetails message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Step.prototype.abort = null; + ProbingDetails.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Step drop. - * @member {google.cloud.networkmanagement.v1beta1.IDropInfo|null|undefined} drop - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Decodes a ProbingDetails message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Step.prototype.drop = null; + ProbingDetails.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.result = reader.int32(); + break; + } + case 2: { + message.verifyTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 3: { + message.error = $root.google.rpc.Status.decode(reader, reader.uint32()); + break; + } + case 4: { + message.abortCause = reader.int32(); + break; + } + case 5: { + message.sentProbeCount = reader.int32(); + break; + } + case 6: { + message.successfulProbeCount = reader.int32(); + break; + } + case 7: { + message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); + break; + } + case 8: { + message.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.decode(reader, reader.uint32()); + break; + } + case 9: { + message.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Step loadBalancer. - * @member {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo|null|undefined} loadBalancer - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Decodes a ProbingDetails message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Step.prototype.loadBalancer = null; + ProbingDetails.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Step network. - * @member {google.cloud.networkmanagement.v1beta1.INetworkInfo|null|undefined} network - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Verifies a ProbingDetails message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Step.prototype.network = null; - - /** - * Step gkeMaster. - * @member {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo|null|undefined} gkeMaster - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.gkeMaster = null; + ProbingDetails.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.result != null && message.hasOwnProperty("result")) + switch (message.result) { + default: + return "result: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + break; + } + if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.verifyTime); + if (error) + return "verifyTime." + error; + } + if (message.error != null && message.hasOwnProperty("error")) { + var error = $root.google.rpc.Status.verify(message.error); + if (error) + return "error." + error; + } + if (message.abortCause != null && message.hasOwnProperty("abortCause")) + switch (message.abortCause) { + default: + return "abortCause: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.sentProbeCount != null && message.hasOwnProperty("sentProbeCount")) + if (!$util.isInteger(message.sentProbeCount)) + return "sentProbeCount: integer expected"; + if (message.successfulProbeCount != null && message.hasOwnProperty("successfulProbeCount")) + if (!$util.isInteger(message.successfulProbeCount)) + return "successfulProbeCount: integer expected"; + if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) { + var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpointInfo); + if (error) + return "endpointInfo." + error; + } + if (message.probingLatency != null && message.hasOwnProperty("probingLatency")) { + var error = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.verify(message.probingLatency); + if (error) + return "probingLatency." + error; + } + if (message.destinationEgressLocation != null && message.hasOwnProperty("destinationEgressLocation")) { + var error = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify(message.destinationEgressLocation); + if (error) + return "destinationEgressLocation." + error; + } + return null; + }; /** - * Step cloudSqlInstance. - * @member {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null|undefined} cloudSqlInstance - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Creates a ProbingDetails message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails} ProbingDetails */ - Step.prototype.cloudSqlInstance = null; + ProbingDetails.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ProbingDetails) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails(); + switch (object.result) { + default: + if (typeof object.result === "number") { + message.result = object.result; + break; + } + break; + case "PROBING_RESULT_UNSPECIFIED": + case 0: + message.result = 0; + break; + case "REACHABLE": + case 1: + message.result = 1; + break; + case "UNREACHABLE": + case 2: + message.result = 2; + break; + case "REACHABILITY_INCONSISTENT": + case 3: + message.result = 3; + break; + case "UNDETERMINED": + case 4: + message.result = 4; + break; + } + if (object.verifyTime != null) { + if (typeof object.verifyTime !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.verifyTime: object expected"); + message.verifyTime = $root.google.protobuf.Timestamp.fromObject(object.verifyTime); + } + if (object.error != null) { + if (typeof object.error !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.error: object expected"); + message.error = $root.google.rpc.Status.fromObject(object.error); + } + switch (object.abortCause) { + default: + if (typeof object.abortCause === "number") { + message.abortCause = object.abortCause; + break; + } + break; + case "PROBING_ABORT_CAUSE_UNSPECIFIED": + case 0: + message.abortCause = 0; + break; + case "PERMISSION_DENIED": + case 1: + message.abortCause = 1; + break; + case "NO_SOURCE_LOCATION": + case 2: + message.abortCause = 2; + break; + } + if (object.sentProbeCount != null) + message.sentProbeCount = object.sentProbeCount | 0; + if (object.successfulProbeCount != null) + message.successfulProbeCount = object.successfulProbeCount | 0; + if (object.endpointInfo != null) { + if (typeof object.endpointInfo !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.endpointInfo: object expected"); + message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpointInfo); + } + if (object.probingLatency != null) { + if (typeof object.probingLatency !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.probingLatency: object expected"); + message.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.fromObject(object.probingLatency); + } + if (object.destinationEgressLocation != null) { + if (typeof object.destinationEgressLocation !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.ProbingDetails.destinationEgressLocation: object expected"); + message.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.fromObject(object.destinationEgressLocation); + } + return message; + }; /** - * Step cloudFunction. - * @member {google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null|undefined} cloudFunction - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Creates a plain object from a ProbingDetails message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails} message ProbingDetails + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - Step.prototype.cloudFunction = null; + ProbingDetails.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.result = options.enums === String ? "PROBING_RESULT_UNSPECIFIED" : 0; + object.verifyTime = null; + object.error = null; + object.abortCause = options.enums === String ? "PROBING_ABORT_CAUSE_UNSPECIFIED" : 0; + object.sentProbeCount = 0; + object.successfulProbeCount = 0; + object.endpointInfo = null; + object.probingLatency = null; + object.destinationEgressLocation = null; + } + if (message.result != null && message.hasOwnProperty("result")) + object.result = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult[message.result] === undefined ? message.result : $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult[message.result] : message.result; + if (message.verifyTime != null && message.hasOwnProperty("verifyTime")) + object.verifyTime = $root.google.protobuf.Timestamp.toObject(message.verifyTime, options); + if (message.error != null && message.hasOwnProperty("error")) + object.error = $root.google.rpc.Status.toObject(message.error, options); + if (message.abortCause != null && message.hasOwnProperty("abortCause")) + object.abortCause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause[message.abortCause] === undefined ? message.abortCause : $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause[message.abortCause] : message.abortCause; + if (message.sentProbeCount != null && message.hasOwnProperty("sentProbeCount")) + object.sentProbeCount = message.sentProbeCount; + if (message.successfulProbeCount != null && message.hasOwnProperty("successfulProbeCount")) + object.successfulProbeCount = message.successfulProbeCount; + if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) + object.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpointInfo, options); + if (message.probingLatency != null && message.hasOwnProperty("probingLatency")) + object.probingLatency = $root.google.cloud.networkmanagement.v1beta1.LatencyDistribution.toObject(message.probingLatency, options); + if (message.destinationEgressLocation != null && message.hasOwnProperty("destinationEgressLocation")) + object.destinationEgressLocation = $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.toObject(message.destinationEgressLocation, options); + return object; + }; /** - * Step appEngineVersion. - * @member {google.cloud.networkmanagement.v1beta1.IAppEngineVersionInfo|null|undefined} appEngineVersion - * @memberof google.cloud.networkmanagement.v1beta1.Step + * Converts this ProbingDetails to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails * @instance + * @returns {Object.} JSON object */ - Step.prototype.appEngineVersion = null; + ProbingDetails.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Step cloudRunRevision. - * @member {google.cloud.networkmanagement.v1beta1.ICloudRunRevisionInfo|null|undefined} cloudRunRevision - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * Gets the default type url for ProbingDetails + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ - Step.prototype.cloudRunRevision = null; + ProbingDetails.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ProbingDetails"; + }; /** - * Step nat. - * @member {google.cloud.networkmanagement.v1beta1.INatInfo|null|undefined} nat - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * ProbingResult enum. + * @name google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingResult + * @enum {number} + * @property {number} PROBING_RESULT_UNSPECIFIED=0 PROBING_RESULT_UNSPECIFIED value + * @property {number} REACHABLE=1 REACHABLE value + * @property {number} UNREACHABLE=2 UNREACHABLE value + * @property {number} REACHABILITY_INCONSISTENT=3 REACHABILITY_INCONSISTENT value + * @property {number} UNDETERMINED=4 UNDETERMINED value */ - Step.prototype.nat = null; + ProbingDetails.ProbingResult = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "PROBING_RESULT_UNSPECIFIED"] = 0; + values[valuesById[1] = "REACHABLE"] = 1; + values[valuesById[2] = "UNREACHABLE"] = 2; + values[valuesById[3] = "REACHABILITY_INCONSISTENT"] = 3; + values[valuesById[4] = "UNDETERMINED"] = 4; + return values; + })(); /** - * Step proxyConnection. - * @member {google.cloud.networkmanagement.v1beta1.IProxyConnectionInfo|null|undefined} proxyConnection - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance + * ProbingAbortCause enum. + * @name google.cloud.networkmanagement.v1beta1.ProbingDetails.ProbingAbortCause + * @enum {number} + * @property {number} PROBING_ABORT_CAUSE_UNSPECIFIED=0 PROBING_ABORT_CAUSE_UNSPECIFIED value + * @property {number} PERMISSION_DENIED=1 PERMISSION_DENIED value + * @property {number} NO_SOURCE_LOCATION=2 NO_SOURCE_LOCATION value */ - Step.prototype.proxyConnection = null; + ProbingDetails.ProbingAbortCause = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "PROBING_ABORT_CAUSE_UNSPECIFIED"] = 0; + values[valuesById[1] = "PERMISSION_DENIED"] = 1; + values[valuesById[2] = "NO_SOURCE_LOCATION"] = 2; + return values; + })(); - /** - * Step loadBalancerBackendInfo. - * @member {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackendInfo|null|undefined} loadBalancerBackendInfo - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.loadBalancerBackendInfo = null; + ProbingDetails.EdgeLocation = (function() { - /** - * Step storageBucket. - * @member {google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null|undefined} storageBucket - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Step.prototype.storageBucket = null; + /** + * Properties of an EdgeLocation. + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @interface IEdgeLocation + * @property {string|null} [metropolitanArea] EdgeLocation metropolitanArea + */ - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * Constructs a new EdgeLocation. + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails + * @classdesc Represents an EdgeLocation. + * @implements IEdgeLocation + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation=} [properties] Properties to set + */ + function EdgeLocation(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Step stepInfo. - * @member {"instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|undefined} stepInfo - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @instance - */ - Object.defineProperty(Step.prototype, "stepInfo", { - get: $util.oneOfGetter($oneOfFields = ["instance", "firewall", "route", "endpoint", "googleService", "forwardingRule", "vpnGateway", "vpnTunnel", "vpcConnector", "deliver", "forward", "abort", "drop", "loadBalancer", "network", "gkeMaster", "cloudSqlInstance", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", "storageBucket"]), - set: $util.oneOfSetter($oneOfFields) - }); + /** + * EdgeLocation metropolitanArea. + * @member {string} metropolitanArea + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @instance + */ + EdgeLocation.prototype.metropolitanArea = ""; - /** - * Creates a new Step instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {google.cloud.networkmanagement.v1beta1.IStep=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.Step} Step instance - */ - Step.create = function create(properties) { - return new Step(properties); - }; + /** + * Creates a new EdgeLocation instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation instance + */ + EdgeLocation.create = function create(properties) { + return new EdgeLocation(properties); + }; - /** - * Encodes the specified Step message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Step.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {google.cloud.networkmanagement.v1beta1.IStep} message Step message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Step.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.description); - if (message.state != null && Object.hasOwnProperty.call(message, "state")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.state); - if (message.causesDrop != null && Object.hasOwnProperty.call(message, "causesDrop")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.causesDrop); - if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.projectId); - if (message.instance != null && Object.hasOwnProperty.call(message, "instance")) - $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.encode(message.instance, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.firewall != null && Object.hasOwnProperty.call(message, "firewall")) - $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.encode(message.firewall, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - if (message.route != null && Object.hasOwnProperty.call(message, "route")) - $root.google.cloud.networkmanagement.v1beta1.RouteInfo.encode(message.route, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - if (message.endpoint != null && Object.hasOwnProperty.call(message, "endpoint")) - $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpoint, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.forwardingRule != null && Object.hasOwnProperty.call(message, "forwardingRule")) - $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.encode(message.forwardingRule, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); - if (message.vpnGateway != null && Object.hasOwnProperty.call(message, "vpnGateway")) - $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.encode(message.vpnGateway, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); - if (message.vpnTunnel != null && Object.hasOwnProperty.call(message, "vpnTunnel")) - $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.encode(message.vpnTunnel, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); - if (message.deliver != null && Object.hasOwnProperty.call(message, "deliver")) - $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.encode(message.deliver, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); - if (message.forward != null && Object.hasOwnProperty.call(message, "forward")) - $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.encode(message.forward, writer.uint32(/* id 13, wireType 2 =*/106).fork()).ldelim(); - if (message.abort != null && Object.hasOwnProperty.call(message, "abort")) - $root.google.cloud.networkmanagement.v1beta1.AbortInfo.encode(message.abort, writer.uint32(/* id 14, wireType 2 =*/114).fork()).ldelim(); - if (message.drop != null && Object.hasOwnProperty.call(message, "drop")) - $root.google.cloud.networkmanagement.v1beta1.DropInfo.encode(message.drop, writer.uint32(/* id 15, wireType 2 =*/122).fork()).ldelim(); - if (message.loadBalancer != null && Object.hasOwnProperty.call(message, "loadBalancer")) - $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.encode(message.loadBalancer, writer.uint32(/* id 16, wireType 2 =*/130).fork()).ldelim(); - if (message.network != null && Object.hasOwnProperty.call(message, "network")) - $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.encode(message.network, writer.uint32(/* id 17, wireType 2 =*/138).fork()).ldelim(); - if (message.gkeMaster != null && Object.hasOwnProperty.call(message, "gkeMaster")) - $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.encode(message.gkeMaster, writer.uint32(/* id 18, wireType 2 =*/146).fork()).ldelim(); - if (message.cloudSqlInstance != null && Object.hasOwnProperty.call(message, "cloudSqlInstance")) - $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.encode(message.cloudSqlInstance, writer.uint32(/* id 19, wireType 2 =*/154).fork()).ldelim(); - if (message.cloudFunction != null && Object.hasOwnProperty.call(message, "cloudFunction")) - $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.encode(message.cloudFunction, writer.uint32(/* id 20, wireType 2 =*/162).fork()).ldelim(); - if (message.vpcConnector != null && Object.hasOwnProperty.call(message, "vpcConnector")) - $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.encode(message.vpcConnector, writer.uint32(/* id 21, wireType 2 =*/170).fork()).ldelim(); - if (message.appEngineVersion != null && Object.hasOwnProperty.call(message, "appEngineVersion")) - $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.encode(message.appEngineVersion, writer.uint32(/* id 22, wireType 2 =*/178).fork()).ldelim(); - if (message.cloudRunRevision != null && Object.hasOwnProperty.call(message, "cloudRunRevision")) - $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.encode(message.cloudRunRevision, writer.uint32(/* id 23, wireType 2 =*/186).fork()).ldelim(); - if (message.googleService != null && Object.hasOwnProperty.call(message, "googleService")) - $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.encode(message.googleService, writer.uint32(/* id 24, wireType 2 =*/194).fork()).ldelim(); - if (message.nat != null && Object.hasOwnProperty.call(message, "nat")) - $root.google.cloud.networkmanagement.v1beta1.NatInfo.encode(message.nat, writer.uint32(/* id 25, wireType 2 =*/202).fork()).ldelim(); - if (message.proxyConnection != null && Object.hasOwnProperty.call(message, "proxyConnection")) - $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.encode(message.proxyConnection, writer.uint32(/* id 26, wireType 2 =*/210).fork()).ldelim(); - if (message.loadBalancerBackendInfo != null && Object.hasOwnProperty.call(message, "loadBalancerBackendInfo")) - $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.encode(message.loadBalancerBackendInfo, writer.uint32(/* id 27, wireType 2 =*/218).fork()).ldelim(); - if (message.storageBucket != null && Object.hasOwnProperty.call(message, "storageBucket")) - $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.encode(message.storageBucket, writer.uint32(/* id 28, wireType 2 =*/226).fork()).ldelim(); - return writer; - }; + /** + * Encodes the specified EdgeLocation message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation} message EdgeLocation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EdgeLocation.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.metropolitanArea != null && Object.hasOwnProperty.call(message, "metropolitanArea")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.metropolitanArea); + return writer; + }; - /** - * Encodes the specified Step message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Step.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {google.cloud.networkmanagement.v1beta1.IStep} message Step message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Step.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified EdgeLocation message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.IEdgeLocation} message EdgeLocation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EdgeLocation.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a Step message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.Step} Step - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Step.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Step(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.description = reader.string(); - break; - } - case 2: { - message.state = reader.int32(); - break; - } - case 3: { - message.causesDrop = reader.bool(); - break; - } - case 4: { - message.projectId = reader.string(); + /** + * Decodes an EdgeLocation message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EdgeLocation.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.metropolitanArea = reader.string(); + break; + } + default: + reader.skipType(tag & 7); break; } - case 5: { - message.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.decode(reader, reader.uint32()); - break; - } - case 6: { - message.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.decode(reader, reader.uint32()); - break; - } - case 7: { - message.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.decode(reader, reader.uint32()); - break; - } - case 8: { - message.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); - break; - } - case 24: { - message.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.decode(reader, reader.uint32()); - break; - } - case 9: { - message.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.decode(reader, reader.uint32()); - break; - } - case 10: { - message.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.decode(reader, reader.uint32()); - break; - } - case 11: { - message.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.decode(reader, reader.uint32()); - break; - } - case 21: { - message.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.decode(reader, reader.uint32()); - break; - } - case 12: { - message.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.decode(reader, reader.uint32()); - break; - } - case 13: { - message.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.decode(reader, reader.uint32()); - break; - } - case 14: { - message.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.decode(reader, reader.uint32()); - break; - } - case 15: { - message.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.decode(reader, reader.uint32()); - break; - } - case 16: { - message.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.decode(reader, reader.uint32()); - break; - } - case 17: { - message.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.decode(reader, reader.uint32()); - break; - } - case 18: { - message.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.decode(reader, reader.uint32()); - break; - } - case 19: { - message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.decode(reader, reader.uint32()); - break; - } - case 20: { - message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.decode(reader, reader.uint32()); - break; - } - case 22: { - message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.decode(reader, reader.uint32()); - break; - } - case 23: { - message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.decode(reader, reader.uint32()); - break; - } - case 25: { - message.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.decode(reader, reader.uint32()); - break; - } - case 26: { - message.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.decode(reader, reader.uint32()); - break; - } - case 27: { - message.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.decode(reader, reader.uint32()); - break; - } - case 28: { - message.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; + + /** + * Decodes an EdgeLocation message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EdgeLocation.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EdgeLocation message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EdgeLocation.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.metropolitanArea != null && message.hasOwnProperty("metropolitanArea")) + if (!$util.isString(message.metropolitanArea)) + return "metropolitanArea: string expected"; + return null; + }; + + /** + * Creates an EdgeLocation message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} EdgeLocation + */ + EdgeLocation.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation(); + if (object.metropolitanArea != null) + message.metropolitanArea = String(object.metropolitanArea); + return message; + }; + + /** + * Creates a plain object from an EdgeLocation message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation} message EdgeLocation + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EdgeLocation.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.metropolitanArea = ""; + if (message.metropolitanArea != null && message.hasOwnProperty("metropolitanArea")) + object.metropolitanArea = message.metropolitanArea; + return object; + }; + + /** + * Converts this EdgeLocation to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @instance + * @returns {Object.} JSON object + */ + EdgeLocation.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EdgeLocation + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EdgeLocation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ProbingDetails.EdgeLocation"; + }; + + return EdgeLocation; + })(); + + return ProbingDetails; + })(); + + v1beta1.Trace = (function() { /** - * Decodes a Step message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.Step} Step - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Properties of a Trace. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface ITrace + * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpointInfo] Trace endpointInfo + * @property {Array.|null} [steps] Trace steps + * @property {number|null} [forwardTraceId] Trace forwardTraceId */ - Step.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies a Step message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Constructs a new Trace. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a Trace. + * @implements ITrace + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.ITrace=} [properties] Properties to set */ - Step.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.state != null && message.hasOwnProperty("state")) - switch (message.state) { - default: - return "state: enum value expected"; - case 0: - case 1: - case 2: - case 27: - case 3: - case 21: - case 22: - case 23: - case 25: - case 26: - case 29: - case 30: - case 4: - case 5: - case 6: - case 7: - case 28: - case 8: - case 9: - case 10: - case 11: - case 12: - case 13: - case 24: - case 14: - case 15: - case 16: - case 17: - case 18: - case 19: - case 20: + function Trace(properties) { + this.steps = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Trace endpointInfo. + * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @instance + */ + Trace.prototype.endpointInfo = null; + + /** + * Trace steps. + * @member {Array.} steps + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @instance + */ + Trace.prototype.steps = $util.emptyArray; + + /** + * Trace forwardTraceId. + * @member {number} forwardTraceId + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @instance + */ + Trace.prototype.forwardTraceId = 0; + + /** + * Creates a new Trace instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {google.cloud.networkmanagement.v1beta1.ITrace=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace instance + */ + Trace.create = function create(properties) { + return new Trace(properties); + }; + + /** + * Encodes the specified Trace message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Trace.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {google.cloud.networkmanagement.v1beta1.ITrace} message Trace message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Trace.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.endpointInfo != null && Object.hasOwnProperty.call(message, "endpointInfo")) + $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpointInfo, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.steps != null && message.steps.length) + for (var i = 0; i < message.steps.length; ++i) + $root.google.cloud.networkmanagement.v1beta1.Step.encode(message.steps[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.forwardTraceId != null && Object.hasOwnProperty.call(message, "forwardTraceId")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.forwardTraceId); + return writer; + }; + + /** + * Encodes the specified Trace message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Trace.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {google.cloud.networkmanagement.v1beta1.ITrace} message Trace message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Trace.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Trace message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Trace.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Trace(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); + break; + } + case 2: { + if (!(message.steps && message.steps.length)) + message.steps = []; + message.steps.push($root.google.cloud.networkmanagement.v1beta1.Step.decode(reader, reader.uint32())); + break; + } + case 4: { + message.forwardTraceId = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); break; } - if (message.causesDrop != null && message.hasOwnProperty("causesDrop")) - if (typeof message.causesDrop !== "boolean") - return "causesDrop: boolean expected"; - if (message.projectId != null && message.hasOwnProperty("projectId")) - if (!$util.isString(message.projectId)) - return "projectId: string expected"; - if (message.instance != null && message.hasOwnProperty("instance")) { - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.verify(message.instance); - if (error) - return "instance." + error; - } } - if (message.firewall != null && message.hasOwnProperty("firewall")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.verify(message.firewall); - if (error) - return "firewall." + error; - } + return message; + }; + + /** + * Decodes a Trace message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Trace.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Trace message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Trace.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) { + var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpointInfo); + if (error) + return "endpointInfo." + error; } - if (message.route != null && message.hasOwnProperty("route")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.verify(message.route); + if (message.steps != null && message.hasOwnProperty("steps")) { + if (!Array.isArray(message.steps)) + return "steps: array expected"; + for (var i = 0; i < message.steps.length; ++i) { + var error = $root.google.cloud.networkmanagement.v1beta1.Step.verify(message.steps[i]); if (error) - return "route." + error; + return "steps." + error; } } - if (message.endpoint != null && message.hasOwnProperty("endpoint")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpoint); - if (error) - return "endpoint." + error; - } + if (message.forwardTraceId != null && message.hasOwnProperty("forwardTraceId")) + if (!$util.isInteger(message.forwardTraceId)) + return "forwardTraceId: integer expected"; + return null; + }; + + /** + * Creates a Trace message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.Trace} Trace + */ + Trace.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Trace) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.Trace(); + if (object.endpointInfo != null) { + if (typeof object.endpointInfo !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.endpointInfo: object expected"); + message.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpointInfo); } - if (message.googleService != null && message.hasOwnProperty("googleService")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify(message.googleService); - if (error) - return "googleService." + error; + if (object.steps) { + if (!Array.isArray(object.steps)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.steps: array expected"); + message.steps = []; + for (var i = 0; i < object.steps.length; ++i) { + if (typeof object.steps[i] !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Trace.steps: object expected"); + message.steps[i] = $root.google.cloud.networkmanagement.v1beta1.Step.fromObject(object.steps[i]); } } - if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify(message.forwardingRule); - if (error) - return "forwardingRule." + error; - } - } - if (message.vpnGateway != null && message.hasOwnProperty("vpnGateway")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify(message.vpnGateway); - if (error) - return "vpnGateway." + error; - } - } - if (message.vpnTunnel != null && message.hasOwnProperty("vpnTunnel")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify(message.vpnTunnel); - if (error) - return "vpnTunnel." + error; - } - } - if (message.vpcConnector != null && message.hasOwnProperty("vpcConnector")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.verify(message.vpcConnector); - if (error) - return "vpcConnector." + error; - } - } - if (message.deliver != null && message.hasOwnProperty("deliver")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.verify(message.deliver); - if (error) - return "deliver." + error; - } - } - if (message.forward != null && message.hasOwnProperty("forward")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.verify(message.forward); - if (error) - return "forward." + error; - } - } - if (message.abort != null && message.hasOwnProperty("abort")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.verify(message.abort); - if (error) - return "abort." + error; - } - } - if (message.drop != null && message.hasOwnProperty("drop")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.DropInfo.verify(message.drop); - if (error) - return "drop." + error; - } - } - if (message.loadBalancer != null && message.hasOwnProperty("loadBalancer")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify(message.loadBalancer); - if (error) - return "loadBalancer." + error; - } - } - if (message.network != null && message.hasOwnProperty("network")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.verify(message.network); - if (error) - return "network." + error; - } - } - if (message.gkeMaster != null && message.hasOwnProperty("gkeMaster")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify(message.gkeMaster); - if (error) - return "gkeMaster." + error; - } - } - if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify(message.cloudSqlInstance); - if (error) - return "cloudSqlInstance." + error; - } - } - if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.verify(message.cloudFunction); - if (error) - return "cloudFunction." + error; - } - } - if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.verify(message.appEngineVersion); - if (error) - return "appEngineVersion." + error; - } - } - if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.verify(message.cloudRunRevision); - if (error) - return "cloudRunRevision." + error; - } - } - if (message.nat != null && message.hasOwnProperty("nat")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.NatInfo.verify(message.nat); - if (error) - return "nat." + error; - } - } - if (message.proxyConnection != null && message.hasOwnProperty("proxyConnection")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.verify(message.proxyConnection); - if (error) - return "proxyConnection." + error; - } - } - if (message.loadBalancerBackendInfo != null && message.hasOwnProperty("loadBalancerBackendInfo")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.verify(message.loadBalancerBackendInfo); - if (error) - return "loadBalancerBackendInfo." + error; - } + if (object.forwardTraceId != null) + message.forwardTraceId = object.forwardTraceId | 0; + return message; + }; + + /** + * Creates a plain object from a Trace message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @static + * @param {google.cloud.networkmanagement.v1beta1.Trace} message Trace + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Trace.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.steps = []; + if (options.defaults) { + object.endpointInfo = null; + object.forwardTraceId = 0; } - if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) { - if (properties.stepInfo === 1) - return "stepInfo: multiple values"; - properties.stepInfo = 1; - { - var error = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.verify(message.storageBucket); - if (error) - return "storageBucket." + error; - } + if (message.endpointInfo != null && message.hasOwnProperty("endpointInfo")) + object.endpointInfo = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpointInfo, options); + if (message.steps && message.steps.length) { + object.steps = []; + for (var j = 0; j < message.steps.length; ++j) + object.steps[j] = $root.google.cloud.networkmanagement.v1beta1.Step.toObject(message.steps[j], options); } - return null; + if (message.forwardTraceId != null && message.hasOwnProperty("forwardTraceId")) + object.forwardTraceId = message.forwardTraceId; + return object; }; /** - * Creates a Step message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.Step + * Converts this Trace to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.Trace + * @instance + * @returns {Object.} JSON object + */ + Trace.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Trace + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.Trace * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.Step} Step + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ - Step.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Step) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.Step(); - if (object.description != null) - message.description = String(object.description); - switch (object.state) { - default: - if (typeof object.state === "number") { - message.state = object.state; - break; - } - break; - case "STATE_UNSPECIFIED": - case 0: - message.state = 0; - break; - case "START_FROM_INSTANCE": - case 1: - message.state = 1; - break; - case "START_FROM_INTERNET": - case 2: - message.state = 2; - break; - case "START_FROM_GOOGLE_SERVICE": - case 27: - message.state = 27; - break; - case "START_FROM_PRIVATE_NETWORK": - case 3: - message.state = 3; - break; - case "START_FROM_GKE_MASTER": - case 21: - message.state = 21; - break; - case "START_FROM_CLOUD_SQL_INSTANCE": - case 22: - message.state = 22; - break; - case "START_FROM_CLOUD_FUNCTION": - case 23: - message.state = 23; - break; - case "START_FROM_APP_ENGINE_VERSION": - case 25: - message.state = 25; - break; - case "START_FROM_CLOUD_RUN_REVISION": - case 26: - message.state = 26; - break; - case "START_FROM_STORAGE_BUCKET": - case 29: - message.state = 29; - break; - case "START_FROM_PSC_PUBLISHED_SERVICE": - case 30: - message.state = 30; - break; - case "APPLY_INGRESS_FIREWALL_RULE": - case 4: - message.state = 4; - break; - case "APPLY_EGRESS_FIREWALL_RULE": - case 5: - message.state = 5; - break; - case "APPLY_ROUTE": - case 6: - message.state = 6; - break; - case "APPLY_FORWARDING_RULE": - case 7: - message.state = 7; - break; - case "ANALYZE_LOAD_BALANCER_BACKEND": - case 28: - message.state = 28; - break; - case "SPOOFING_APPROVED": - case 8: - message.state = 8; - break; - case "ARRIVE_AT_INSTANCE": - case 9: - message.state = 9; - break; - case "ARRIVE_AT_INTERNAL_LOAD_BALANCER": - case 10: - message.state = 10; - break; - case "ARRIVE_AT_EXTERNAL_LOAD_BALANCER": - case 11: - message.state = 11; - break; - case "ARRIVE_AT_VPN_GATEWAY": - case 12: - message.state = 12; - break; - case "ARRIVE_AT_VPN_TUNNEL": - case 13: - message.state = 13; - break; - case "ARRIVE_AT_VPC_CONNECTOR": - case 24: - message.state = 24; - break; - case "NAT": - case 14: - message.state = 14; - break; - case "PROXY_CONNECTION": - case 15: - message.state = 15; - break; - case "DELIVER": - case 16: - message.state = 16; - break; - case "DROP": - case 17: - message.state = 17; - break; - case "FORWARD": - case 18: - message.state = 18; - break; - case "ABORT": - case 19: - message.state = 19; - break; - case "VIEWER_PERMISSION_MISSING": - case 20: - message.state = 20; - break; - } - if (object.causesDrop != null) - message.causesDrop = Boolean(object.causesDrop); - if (object.projectId != null) - message.projectId = String(object.projectId); - if (object.instance != null) { - if (typeof object.instance !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.instance: object expected"); - message.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.fromObject(object.instance); - } - if (object.firewall != null) { - if (typeof object.firewall !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.firewall: object expected"); - message.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.fromObject(object.firewall); - } - if (object.route != null) { - if (typeof object.route !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.route: object expected"); - message.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.fromObject(object.route); - } - if (object.endpoint != null) { - if (typeof object.endpoint !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.endpoint: object expected"); - message.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpoint); - } - if (object.googleService != null) { - if (typeof object.googleService !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.googleService: object expected"); - message.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.fromObject(object.googleService); - } - if (object.forwardingRule != null) { - if (typeof object.forwardingRule !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.forwardingRule: object expected"); - message.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.fromObject(object.forwardingRule); - } - if (object.vpnGateway != null) { - if (typeof object.vpnGateway !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpnGateway: object expected"); - message.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.fromObject(object.vpnGateway); - } - if (object.vpnTunnel != null) { - if (typeof object.vpnTunnel !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpnTunnel: object expected"); - message.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.fromObject(object.vpnTunnel); - } - if (object.vpcConnector != null) { - if (typeof object.vpcConnector !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpcConnector: object expected"); - message.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.fromObject(object.vpcConnector); - } - if (object.deliver != null) { - if (typeof object.deliver !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.deliver: object expected"); - message.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.fromObject(object.deliver); - } - if (object.forward != null) { - if (typeof object.forward !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.forward: object expected"); - message.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.fromObject(object.forward); - } - if (object.abort != null) { - if (typeof object.abort !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.abort: object expected"); - message.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.fromObject(object.abort); - } - if (object.drop != null) { - if (typeof object.drop !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.drop: object expected"); - message.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.fromObject(object.drop); - } - if (object.loadBalancer != null) { - if (typeof object.loadBalancer !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.loadBalancer: object expected"); - message.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.fromObject(object.loadBalancer); - } - if (object.network != null) { - if (typeof object.network !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.network: object expected"); - message.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.fromObject(object.network); - } - if (object.gkeMaster != null) { - if (typeof object.gkeMaster !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.gkeMaster: object expected"); - message.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.fromObject(object.gkeMaster); - } - if (object.cloudSqlInstance != null) { - if (typeof object.cloudSqlInstance !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudSqlInstance: object expected"); - message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.fromObject(object.cloudSqlInstance); - } - if (object.cloudFunction != null) { - if (typeof object.cloudFunction !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudFunction: object expected"); - message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.fromObject(object.cloudFunction); - } - if (object.appEngineVersion != null) { - if (typeof object.appEngineVersion !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.appEngineVersion: object expected"); - message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.fromObject(object.appEngineVersion); - } - if (object.cloudRunRevision != null) { - if (typeof object.cloudRunRevision !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudRunRevision: object expected"); - message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.fromObject(object.cloudRunRevision); - } - if (object.nat != null) { - if (typeof object.nat !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.nat: object expected"); - message.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.fromObject(object.nat); - } - if (object.proxyConnection != null) { - if (typeof object.proxyConnection !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.proxyConnection: object expected"); - message.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.fromObject(object.proxyConnection); - } - if (object.loadBalancerBackendInfo != null) { - if (typeof object.loadBalancerBackendInfo !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.loadBalancerBackendInfo: object expected"); - message.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.fromObject(object.loadBalancerBackendInfo); - } - if (object.storageBucket != null) { - if (typeof object.storageBucket !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.storageBucket: object expected"); - message.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.fromObject(object.storageBucket); + Trace.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } - return message; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Trace"; }; + return Trace; + })(); + + v1beta1.Step = (function() { + /** - * Creates a plain object from a Step message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {google.cloud.networkmanagement.v1beta1.Step} message Step - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Properties of a Step. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IStep + * @property {string|null} [description] Step description + * @property {google.cloud.networkmanagement.v1beta1.Step.State|null} [state] Step state + * @property {boolean|null} [causesDrop] Step causesDrop + * @property {string|null} [projectId] Step projectId + * @property {google.cloud.networkmanagement.v1beta1.IInstanceInfo|null} [instance] Step instance + * @property {google.cloud.networkmanagement.v1beta1.IFirewallInfo|null} [firewall] Step firewall + * @property {google.cloud.networkmanagement.v1beta1.IRouteInfo|null} [route] Step route + * @property {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null} [endpoint] Step endpoint + * @property {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo|null} [googleService] Step googleService + * @property {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo|null} [forwardingRule] Step forwardingRule + * @property {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo|null} [vpnGateway] Step vpnGateway + * @property {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo|null} [vpnTunnel] Step vpnTunnel + * @property {google.cloud.networkmanagement.v1beta1.IVpcConnectorInfo|null} [vpcConnector] Step vpcConnector + * @property {google.cloud.networkmanagement.v1beta1.IDeliverInfo|null} [deliver] Step deliver + * @property {google.cloud.networkmanagement.v1beta1.IForwardInfo|null} [forward] Step forward + * @property {google.cloud.networkmanagement.v1beta1.IAbortInfo|null} [abort] Step abort + * @property {google.cloud.networkmanagement.v1beta1.IDropInfo|null} [drop] Step drop + * @property {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo|null} [loadBalancer] Step loadBalancer + * @property {google.cloud.networkmanagement.v1beta1.INetworkInfo|null} [network] Step network + * @property {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo|null} [gkeMaster] Step gkeMaster + * @property {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null} [cloudSqlInstance] Step cloudSqlInstance + * @property {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo|null} [redisInstance] Step redisInstance + * @property {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo|null} [redisCluster] Step redisCluster + * @property {google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null} [cloudFunction] Step cloudFunction + * @property {google.cloud.networkmanagement.v1beta1.IAppEngineVersionInfo|null} [appEngineVersion] Step appEngineVersion + * @property {google.cloud.networkmanagement.v1beta1.ICloudRunRevisionInfo|null} [cloudRunRevision] Step cloudRunRevision + * @property {google.cloud.networkmanagement.v1beta1.INatInfo|null} [nat] Step nat + * @property {google.cloud.networkmanagement.v1beta1.IProxyConnectionInfo|null} [proxyConnection] Step proxyConnection + * @property {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackendInfo|null} [loadBalancerBackendInfo] Step loadBalancerBackendInfo + * @property {google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null} [storageBucket] Step storageBucket + * @property {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo|null} [serverlessNeg] Step serverlessNeg */ - Step.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.description = ""; - object.state = options.enums === String ? "STATE_UNSPECIFIED" : 0; - object.causesDrop = false; - object.projectId = ""; - } - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Step.State[message.state] === undefined ? message.state : $root.google.cloud.networkmanagement.v1beta1.Step.State[message.state] : message.state; - if (message.causesDrop != null && message.hasOwnProperty("causesDrop")) - object.causesDrop = message.causesDrop; - if (message.projectId != null && message.hasOwnProperty("projectId")) - object.projectId = message.projectId; - if (message.instance != null && message.hasOwnProperty("instance")) { - object.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.toObject(message.instance, options); - if (options.oneofs) - object.stepInfo = "instance"; - } - if (message.firewall != null && message.hasOwnProperty("firewall")) { - object.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.toObject(message.firewall, options); - if (options.oneofs) - object.stepInfo = "firewall"; - } - if (message.route != null && message.hasOwnProperty("route")) { - object.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.toObject(message.route, options); - if (options.oneofs) - object.stepInfo = "route"; - } - if (message.endpoint != null && message.hasOwnProperty("endpoint")) { - object.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpoint, options); - if (options.oneofs) - object.stepInfo = "endpoint"; - } - if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) { - object.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.toObject(message.forwardingRule, options); - if (options.oneofs) - object.stepInfo = "forwardingRule"; - } - if (message.vpnGateway != null && message.hasOwnProperty("vpnGateway")) { - object.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.toObject(message.vpnGateway, options); - if (options.oneofs) - object.stepInfo = "vpnGateway"; - } - if (message.vpnTunnel != null && message.hasOwnProperty("vpnTunnel")) { - object.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.toObject(message.vpnTunnel, options); - if (options.oneofs) - object.stepInfo = "vpnTunnel"; - } - if (message.deliver != null && message.hasOwnProperty("deliver")) { - object.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.toObject(message.deliver, options); - if (options.oneofs) - object.stepInfo = "deliver"; - } - if (message.forward != null && message.hasOwnProperty("forward")) { - object.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.toObject(message.forward, options); - if (options.oneofs) - object.stepInfo = "forward"; - } - if (message.abort != null && message.hasOwnProperty("abort")) { - object.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.toObject(message.abort, options); - if (options.oneofs) - object.stepInfo = "abort"; - } - if (message.drop != null && message.hasOwnProperty("drop")) { - object.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.toObject(message.drop, options); - if (options.oneofs) - object.stepInfo = "drop"; - } - if (message.loadBalancer != null && message.hasOwnProperty("loadBalancer")) { - object.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.toObject(message.loadBalancer, options); - if (options.oneofs) - object.stepInfo = "loadBalancer"; - } - if (message.network != null && message.hasOwnProperty("network")) { - object.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.toObject(message.network, options); - if (options.oneofs) - object.stepInfo = "network"; - } - if (message.gkeMaster != null && message.hasOwnProperty("gkeMaster")) { - object.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.toObject(message.gkeMaster, options); - if (options.oneofs) - object.stepInfo = "gkeMaster"; - } - if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) { - object.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.toObject(message.cloudSqlInstance, options); - if (options.oneofs) - object.stepInfo = "cloudSqlInstance"; - } - if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { - object.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.toObject(message.cloudFunction, options); - if (options.oneofs) - object.stepInfo = "cloudFunction"; - } - if (message.vpcConnector != null && message.hasOwnProperty("vpcConnector")) { - object.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.toObject(message.vpcConnector, options); - if (options.oneofs) - object.stepInfo = "vpcConnector"; - } - if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { - object.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.toObject(message.appEngineVersion, options); - if (options.oneofs) - object.stepInfo = "appEngineVersion"; - } - if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { - object.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.toObject(message.cloudRunRevision, options); - if (options.oneofs) - object.stepInfo = "cloudRunRevision"; - } - if (message.googleService != null && message.hasOwnProperty("googleService")) { - object.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.toObject(message.googleService, options); - if (options.oneofs) - object.stepInfo = "googleService"; - } - if (message.nat != null && message.hasOwnProperty("nat")) { - object.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.toObject(message.nat, options); - if (options.oneofs) - object.stepInfo = "nat"; - } - if (message.proxyConnection != null && message.hasOwnProperty("proxyConnection")) { - object.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.toObject(message.proxyConnection, options); - if (options.oneofs) - object.stepInfo = "proxyConnection"; - } - if (message.loadBalancerBackendInfo != null && message.hasOwnProperty("loadBalancerBackendInfo")) { - object.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.toObject(message.loadBalancerBackendInfo, options); - if (options.oneofs) - object.stepInfo = "loadBalancerBackendInfo"; - } - if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) { - object.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.toObject(message.storageBucket, options); - if (options.oneofs) - object.stepInfo = "storageBucket"; - } - return object; - }; /** - * Converts this Step to JSON. - * @function toJSON + * Constructs a new Step. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a Step. + * @implements IStep + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IStep=} [properties] Properties to set + */ + function Step(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Step description. + * @member {string} description * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance - * @returns {Object.} JSON object */ - Step.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Step.prototype.description = ""; /** - * Gets the default type url for Step - * @function getTypeUrl + * Step state. + * @member {google.cloud.networkmanagement.v1beta1.Step.State} state * @memberof google.cloud.networkmanagement.v1beta1.Step - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * @instance */ - Step.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Step"; - }; + Step.prototype.state = 0; /** - * State enum. - * @name google.cloud.networkmanagement.v1beta1.Step.State - * @enum {number} - * @property {number} STATE_UNSPECIFIED=0 STATE_UNSPECIFIED value - * @property {number} START_FROM_INSTANCE=1 START_FROM_INSTANCE value - * @property {number} START_FROM_INTERNET=2 START_FROM_INTERNET value - * @property {number} START_FROM_GOOGLE_SERVICE=27 START_FROM_GOOGLE_SERVICE value - * @property {number} START_FROM_PRIVATE_NETWORK=3 START_FROM_PRIVATE_NETWORK value - * @property {number} START_FROM_GKE_MASTER=21 START_FROM_GKE_MASTER value - * @property {number} START_FROM_CLOUD_SQL_INSTANCE=22 START_FROM_CLOUD_SQL_INSTANCE value - * @property {number} START_FROM_CLOUD_FUNCTION=23 START_FROM_CLOUD_FUNCTION value - * @property {number} START_FROM_APP_ENGINE_VERSION=25 START_FROM_APP_ENGINE_VERSION value - * @property {number} START_FROM_CLOUD_RUN_REVISION=26 START_FROM_CLOUD_RUN_REVISION value - * @property {number} START_FROM_STORAGE_BUCKET=29 START_FROM_STORAGE_BUCKET value - * @property {number} START_FROM_PSC_PUBLISHED_SERVICE=30 START_FROM_PSC_PUBLISHED_SERVICE value - * @property {number} APPLY_INGRESS_FIREWALL_RULE=4 APPLY_INGRESS_FIREWALL_RULE value - * @property {number} APPLY_EGRESS_FIREWALL_RULE=5 APPLY_EGRESS_FIREWALL_RULE value - * @property {number} APPLY_ROUTE=6 APPLY_ROUTE value - * @property {number} APPLY_FORWARDING_RULE=7 APPLY_FORWARDING_RULE value - * @property {number} ANALYZE_LOAD_BALANCER_BACKEND=28 ANALYZE_LOAD_BALANCER_BACKEND value - * @property {number} SPOOFING_APPROVED=8 SPOOFING_APPROVED value - * @property {number} ARRIVE_AT_INSTANCE=9 ARRIVE_AT_INSTANCE value - * @property {number} ARRIVE_AT_INTERNAL_LOAD_BALANCER=10 ARRIVE_AT_INTERNAL_LOAD_BALANCER value - * @property {number} ARRIVE_AT_EXTERNAL_LOAD_BALANCER=11 ARRIVE_AT_EXTERNAL_LOAD_BALANCER value - * @property {number} ARRIVE_AT_VPN_GATEWAY=12 ARRIVE_AT_VPN_GATEWAY value - * @property {number} ARRIVE_AT_VPN_TUNNEL=13 ARRIVE_AT_VPN_TUNNEL value - * @property {number} ARRIVE_AT_VPC_CONNECTOR=24 ARRIVE_AT_VPC_CONNECTOR value - * @property {number} NAT=14 NAT value - * @property {number} PROXY_CONNECTION=15 PROXY_CONNECTION value - * @property {number} DELIVER=16 DELIVER value - * @property {number} DROP=17 DROP value - * @property {number} FORWARD=18 FORWARD value - * @property {number} ABORT=19 ABORT value - * @property {number} VIEWER_PERMISSION_MISSING=20 VIEWER_PERMISSION_MISSING value + * Step causesDrop. + * @member {boolean} causesDrop + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - Step.State = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "STATE_UNSPECIFIED"] = 0; - values[valuesById[1] = "START_FROM_INSTANCE"] = 1; - values[valuesById[2] = "START_FROM_INTERNET"] = 2; - values[valuesById[27] = "START_FROM_GOOGLE_SERVICE"] = 27; - values[valuesById[3] = "START_FROM_PRIVATE_NETWORK"] = 3; - values[valuesById[21] = "START_FROM_GKE_MASTER"] = 21; - values[valuesById[22] = "START_FROM_CLOUD_SQL_INSTANCE"] = 22; - values[valuesById[23] = "START_FROM_CLOUD_FUNCTION"] = 23; - values[valuesById[25] = "START_FROM_APP_ENGINE_VERSION"] = 25; - values[valuesById[26] = "START_FROM_CLOUD_RUN_REVISION"] = 26; - values[valuesById[29] = "START_FROM_STORAGE_BUCKET"] = 29; - values[valuesById[30] = "START_FROM_PSC_PUBLISHED_SERVICE"] = 30; - values[valuesById[4] = "APPLY_INGRESS_FIREWALL_RULE"] = 4; - values[valuesById[5] = "APPLY_EGRESS_FIREWALL_RULE"] = 5; - values[valuesById[6] = "APPLY_ROUTE"] = 6; - values[valuesById[7] = "APPLY_FORWARDING_RULE"] = 7; - values[valuesById[28] = "ANALYZE_LOAD_BALANCER_BACKEND"] = 28; - values[valuesById[8] = "SPOOFING_APPROVED"] = 8; - values[valuesById[9] = "ARRIVE_AT_INSTANCE"] = 9; - values[valuesById[10] = "ARRIVE_AT_INTERNAL_LOAD_BALANCER"] = 10; - values[valuesById[11] = "ARRIVE_AT_EXTERNAL_LOAD_BALANCER"] = 11; - values[valuesById[12] = "ARRIVE_AT_VPN_GATEWAY"] = 12; - values[valuesById[13] = "ARRIVE_AT_VPN_TUNNEL"] = 13; - values[valuesById[24] = "ARRIVE_AT_VPC_CONNECTOR"] = 24; - values[valuesById[14] = "NAT"] = 14; - values[valuesById[15] = "PROXY_CONNECTION"] = 15; - values[valuesById[16] = "DELIVER"] = 16; - values[valuesById[17] = "DROP"] = 17; - values[valuesById[18] = "FORWARD"] = 18; - values[valuesById[19] = "ABORT"] = 19; - values[valuesById[20] = "VIEWER_PERMISSION_MISSING"] = 20; - return values; - })(); + Step.prototype.causesDrop = false; - return Step; - })(); + /** + * Step projectId. + * @member {string} projectId + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance + */ + Step.prototype.projectId = ""; - v1beta1.InstanceInfo = (function() { + /** + * Step instance. + * @member {google.cloud.networkmanagement.v1beta1.IInstanceInfo|null|undefined} instance + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance + */ + Step.prototype.instance = null; /** - * Properties of an InstanceInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IInstanceInfo - * @property {string|null} [displayName] InstanceInfo displayName - * @property {string|null} [uri] InstanceInfo uri - * @property {string|null} ["interface"] InstanceInfo interface - * @property {string|null} [networkUri] InstanceInfo networkUri - * @property {string|null} [internalIp] InstanceInfo internalIp - * @property {string|null} [externalIp] InstanceInfo externalIp - * @property {Array.|null} [networkTags] InstanceInfo networkTags - * @property {string|null} [serviceAccount] InstanceInfo serviceAccount + * Step firewall. + * @member {google.cloud.networkmanagement.v1beta1.IFirewallInfo|null|undefined} firewall + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ + Step.prototype.firewall = null; /** - * Constructs a new InstanceInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents an InstanceInfo. - * @implements IInstanceInfo - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo=} [properties] Properties to set + * Step route. + * @member {google.cloud.networkmanagement.v1beta1.IRouteInfo|null|undefined} route + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - function InstanceInfo(properties) { - this.networkTags = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + Step.prototype.route = null; /** - * InstanceInfo displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step endpoint. + * @member {google.cloud.networkmanagement.v1beta1.IEndpointInfo|null|undefined} endpoint + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.displayName = ""; + Step.prototype.endpoint = null; /** - * InstanceInfo uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step googleService. + * @member {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo|null|undefined} googleService + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.uri = ""; + Step.prototype.googleService = null; /** - * InstanceInfo interface. - * @member {string} interface - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step forwardingRule. + * @member {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo|null|undefined} forwardingRule + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype["interface"] = ""; + Step.prototype.forwardingRule = null; /** - * InstanceInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step vpnGateway. + * @member {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo|null|undefined} vpnGateway + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.networkUri = ""; + Step.prototype.vpnGateway = null; /** - * InstanceInfo internalIp. - * @member {string} internalIp - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step vpnTunnel. + * @member {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo|null|undefined} vpnTunnel + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.internalIp = ""; + Step.prototype.vpnTunnel = null; /** - * InstanceInfo externalIp. - * @member {string} externalIp - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step vpcConnector. + * @member {google.cloud.networkmanagement.v1beta1.IVpcConnectorInfo|null|undefined} vpcConnector + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.externalIp = ""; + Step.prototype.vpcConnector = null; /** - * InstanceInfo networkTags. - * @member {Array.} networkTags - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step deliver. + * @member {google.cloud.networkmanagement.v1beta1.IDeliverInfo|null|undefined} deliver + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.networkTags = $util.emptyArray; + Step.prototype.deliver = null; /** - * InstanceInfo serviceAccount. - * @member {string} serviceAccount - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step forward. + * @member {google.cloud.networkmanagement.v1beta1.IForwardInfo|null|undefined} forward + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - InstanceInfo.prototype.serviceAccount = ""; + Step.prototype.forward = null; /** - * Creates a new InstanceInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo instance + * Step abort. + * @member {google.cloud.networkmanagement.v1beta1.IAbortInfo|null|undefined} abort + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.create = function create(properties) { - return new InstanceInfo(properties); - }; + Step.prototype.abort = null; /** - * Encodes the specified InstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.InstanceInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo} message InstanceInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Step drop. + * @member {google.cloud.networkmanagement.v1beta1.IDropInfo|null|undefined} drop + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message["interface"] != null && Object.hasOwnProperty.call(message, "interface")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message["interface"]); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.networkUri); - if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); - if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); - if (message.networkTags != null && message.networkTags.length) - for (var i = 0; i < message.networkTags.length; ++i) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkTags[i]); - if (message.serviceAccount != null && Object.hasOwnProperty.call(message, "serviceAccount")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.serviceAccount); - return writer; - }; + Step.prototype.drop = null; /** - * Encodes the specified InstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.InstanceInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo} message InstanceInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Step loadBalancer. + * @member {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo|null|undefined} loadBalancer + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Step.prototype.loadBalancer = null; /** - * Decodes an InstanceInfo message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Step network. + * @member {google.cloud.networkmanagement.v1beta1.INetworkInfo|null|undefined} network + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.InstanceInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - case 2: { - message.uri = reader.string(); - break; - } - case 3: { - message["interface"] = reader.string(); - break; - } - case 4: { - message.networkUri = reader.string(); - break; - } - case 5: { - message.internalIp = reader.string(); - break; - } - case 6: { - message.externalIp = reader.string(); - break; - } - case 7: { - if (!(message.networkTags && message.networkTags.length)) - message.networkTags = []; - message.networkTags.push(reader.string()); - break; - } - case 8: { - message.serviceAccount = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + Step.prototype.network = null; /** - * Decodes an InstanceInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Step gkeMaster. + * @member {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo|null|undefined} gkeMaster + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + Step.prototype.gkeMaster = null; /** - * Verifies an InstanceInfo message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Step cloudSqlInstance. + * @member {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo|null|undefined} cloudSqlInstance + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - if (message["interface"] != null && message.hasOwnProperty("interface")) - if (!$util.isString(message["interface"])) - return "interface: string expected"; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - if (!$util.isString(message.networkUri)) - return "networkUri: string expected"; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - if (!$util.isString(message.internalIp)) - return "internalIp: string expected"; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - if (!$util.isString(message.externalIp)) - return "externalIp: string expected"; - if (message.networkTags != null && message.hasOwnProperty("networkTags")) { - if (!Array.isArray(message.networkTags)) - return "networkTags: array expected"; - for (var i = 0; i < message.networkTags.length; ++i) - if (!$util.isString(message.networkTags[i])) - return "networkTags: string[] expected"; - } - if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) - if (!$util.isString(message.serviceAccount)) - return "serviceAccount: string expected"; - return null; - }; + Step.prototype.cloudSqlInstance = null; /** - * Creates an InstanceInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo + * Step redisInstance. + * @member {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo|null|undefined} redisInstance + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.InstanceInfo) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.InstanceInfo(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.uri != null) - message.uri = String(object.uri); - if (object["interface"] != null) - message["interface"] = String(object["interface"]); - if (object.networkUri != null) - message.networkUri = String(object.networkUri); - if (object.internalIp != null) - message.internalIp = String(object.internalIp); - if (object.externalIp != null) - message.externalIp = String(object.externalIp); - if (object.networkTags) { - if (!Array.isArray(object.networkTags)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.InstanceInfo.networkTags: array expected"); - message.networkTags = []; - for (var i = 0; i < object.networkTags.length; ++i) - message.networkTags[i] = String(object.networkTags[i]); - } - if (object.serviceAccount != null) - message.serviceAccount = String(object.serviceAccount); - return message; - }; + Step.prototype.redisInstance = null; /** - * Creates a plain object from an InstanceInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.InstanceInfo} message InstanceInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Step redisCluster. + * @member {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo|null|undefined} redisCluster + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.networkTags = []; - if (options.defaults) { - object.displayName = ""; - object.uri = ""; - object["interface"] = ""; - object.networkUri = ""; - object.internalIp = ""; - object.externalIp = ""; - object.serviceAccount = ""; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - if (message["interface"] != null && message.hasOwnProperty("interface")) - object["interface"] = message["interface"]; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - object.networkUri = message.networkUri; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - object.internalIp = message.internalIp; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - object.externalIp = message.externalIp; - if (message.networkTags && message.networkTags.length) { - object.networkTags = []; - for (var j = 0; j < message.networkTags.length; ++j) - object.networkTags[j] = message.networkTags[j]; - } - if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) - object.serviceAccount = message.serviceAccount; - return object; - }; + Step.prototype.redisCluster = null; /** - * Converts this InstanceInfo to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo + * Step cloudFunction. + * @member {google.cloud.networkmanagement.v1beta1.ICloudFunctionInfo|null|undefined} cloudFunction + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance - * @returns {Object.} JSON object */ - InstanceInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Step.prototype.cloudFunction = null; /** - * Gets the default type url for InstanceInfo - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Step appEngineVersion. + * @member {google.cloud.networkmanagement.v1beta1.IAppEngineVersionInfo|null|undefined} appEngineVersion + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - InstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.InstanceInfo"; - }; - - return InstanceInfo; - })(); - - v1beta1.NetworkInfo = (function() { + Step.prototype.appEngineVersion = null; /** - * Properties of a NetworkInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface INetworkInfo - * @property {string|null} [displayName] NetworkInfo displayName - * @property {string|null} [uri] NetworkInfo uri - * @property {string|null} [matchedIpRange] NetworkInfo matchedIpRange + * Step cloudRunRevision. + * @member {google.cloud.networkmanagement.v1beta1.ICloudRunRevisionInfo|null|undefined} cloudRunRevision + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ + Step.prototype.cloudRunRevision = null; /** - * Constructs a new NetworkInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a NetworkInfo. - * @implements INetworkInfo - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo=} [properties] Properties to set + * Step nat. + * @member {google.cloud.networkmanagement.v1beta1.INatInfo|null|undefined} nat + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - function NetworkInfo(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + Step.prototype.nat = null; /** - * NetworkInfo displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * Step proxyConnection. + * @member {google.cloud.networkmanagement.v1beta1.IProxyConnectionInfo|null|undefined} proxyConnection + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - NetworkInfo.prototype.displayName = ""; + Step.prototype.proxyConnection = null; /** - * NetworkInfo uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * Step loadBalancerBackendInfo. + * @member {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackendInfo|null|undefined} loadBalancerBackendInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - NetworkInfo.prototype.uri = ""; + Step.prototype.loadBalancerBackendInfo = null; /** - * NetworkInfo matchedIpRange. - * @member {string} matchedIpRange - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * Step storageBucket. + * @member {google.cloud.networkmanagement.v1beta1.IStorageBucketInfo|null|undefined} storageBucket + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance */ - NetworkInfo.prototype.matchedIpRange = ""; + Step.prototype.storageBucket = null; /** - * Creates a new NetworkInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo instance + * Step serverlessNeg. + * @member {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo|null|undefined} serverlessNeg + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance */ - NetworkInfo.create = function create(properties) { - return new NetworkInfo(properties); - }; + Step.prototype.serverlessNeg = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Encodes the specified NetworkInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.NetworkInfo.verify|verify} messages. + * Step stepInfo. + * @member {"instance"|"firewall"|"route"|"endpoint"|"googleService"|"forwardingRule"|"vpnGateway"|"vpnTunnel"|"vpcConnector"|"deliver"|"forward"|"abort"|"drop"|"loadBalancer"|"network"|"gkeMaster"|"cloudSqlInstance"|"redisInstance"|"redisCluster"|"cloudFunction"|"appEngineVersion"|"cloudRunRevision"|"nat"|"proxyConnection"|"loadBalancerBackendInfo"|"storageBucket"|"serverlessNeg"|undefined} stepInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @instance + */ + Object.defineProperty(Step.prototype, "stepInfo", { + get: $util.oneOfGetter($oneOfFields = ["instance", "firewall", "route", "endpoint", "googleService", "forwardingRule", "vpnGateway", "vpnTunnel", "vpcConnector", "deliver", "forward", "abort", "drop", "loadBalancer", "network", "gkeMaster", "cloudSqlInstance", "redisInstance", "redisCluster", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", "storageBucket", "serverlessNeg"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new Step instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @static + * @param {google.cloud.networkmanagement.v1beta1.IStep=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.Step} Step instance + */ + Step.create = function create(properties) { + return new Step(properties); + }; + + /** + * Encodes the specified Step message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Step.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static - * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo} message NetworkInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IStep} message Step message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NetworkInfo.encode = function encode(message, writer) { + Step.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.matchedIpRange != null && Object.hasOwnProperty.call(message, "matchedIpRange")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.matchedIpRange); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.description); + if (message.state != null && Object.hasOwnProperty.call(message, "state")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.state); + if (message.causesDrop != null && Object.hasOwnProperty.call(message, "causesDrop")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.causesDrop); + if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.projectId); + if (message.instance != null && Object.hasOwnProperty.call(message, "instance")) + $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.encode(message.instance, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.firewall != null && Object.hasOwnProperty.call(message, "firewall")) + $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.encode(message.firewall, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.route != null && Object.hasOwnProperty.call(message, "route")) + $root.google.cloud.networkmanagement.v1beta1.RouteInfo.encode(message.route, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.endpoint != null && Object.hasOwnProperty.call(message, "endpoint")) + $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.encode(message.endpoint, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.forwardingRule != null && Object.hasOwnProperty.call(message, "forwardingRule")) + $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.encode(message.forwardingRule, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + if (message.vpnGateway != null && Object.hasOwnProperty.call(message, "vpnGateway")) + $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.encode(message.vpnGateway, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim(); + if (message.vpnTunnel != null && Object.hasOwnProperty.call(message, "vpnTunnel")) + $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.encode(message.vpnTunnel, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); + if (message.deliver != null && Object.hasOwnProperty.call(message, "deliver")) + $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.encode(message.deliver, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); + if (message.forward != null && Object.hasOwnProperty.call(message, "forward")) + $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.encode(message.forward, writer.uint32(/* id 13, wireType 2 =*/106).fork()).ldelim(); + if (message.abort != null && Object.hasOwnProperty.call(message, "abort")) + $root.google.cloud.networkmanagement.v1beta1.AbortInfo.encode(message.abort, writer.uint32(/* id 14, wireType 2 =*/114).fork()).ldelim(); + if (message.drop != null && Object.hasOwnProperty.call(message, "drop")) + $root.google.cloud.networkmanagement.v1beta1.DropInfo.encode(message.drop, writer.uint32(/* id 15, wireType 2 =*/122).fork()).ldelim(); + if (message.loadBalancer != null && Object.hasOwnProperty.call(message, "loadBalancer")) + $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.encode(message.loadBalancer, writer.uint32(/* id 16, wireType 2 =*/130).fork()).ldelim(); + if (message.network != null && Object.hasOwnProperty.call(message, "network")) + $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.encode(message.network, writer.uint32(/* id 17, wireType 2 =*/138).fork()).ldelim(); + if (message.gkeMaster != null && Object.hasOwnProperty.call(message, "gkeMaster")) + $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.encode(message.gkeMaster, writer.uint32(/* id 18, wireType 2 =*/146).fork()).ldelim(); + if (message.cloudSqlInstance != null && Object.hasOwnProperty.call(message, "cloudSqlInstance")) + $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.encode(message.cloudSqlInstance, writer.uint32(/* id 19, wireType 2 =*/154).fork()).ldelim(); + if (message.cloudFunction != null && Object.hasOwnProperty.call(message, "cloudFunction")) + $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.encode(message.cloudFunction, writer.uint32(/* id 20, wireType 2 =*/162).fork()).ldelim(); + if (message.vpcConnector != null && Object.hasOwnProperty.call(message, "vpcConnector")) + $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.encode(message.vpcConnector, writer.uint32(/* id 21, wireType 2 =*/170).fork()).ldelim(); + if (message.appEngineVersion != null && Object.hasOwnProperty.call(message, "appEngineVersion")) + $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.encode(message.appEngineVersion, writer.uint32(/* id 22, wireType 2 =*/178).fork()).ldelim(); + if (message.cloudRunRevision != null && Object.hasOwnProperty.call(message, "cloudRunRevision")) + $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.encode(message.cloudRunRevision, writer.uint32(/* id 23, wireType 2 =*/186).fork()).ldelim(); + if (message.googleService != null && Object.hasOwnProperty.call(message, "googleService")) + $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.encode(message.googleService, writer.uint32(/* id 24, wireType 2 =*/194).fork()).ldelim(); + if (message.nat != null && Object.hasOwnProperty.call(message, "nat")) + $root.google.cloud.networkmanagement.v1beta1.NatInfo.encode(message.nat, writer.uint32(/* id 25, wireType 2 =*/202).fork()).ldelim(); + if (message.proxyConnection != null && Object.hasOwnProperty.call(message, "proxyConnection")) + $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.encode(message.proxyConnection, writer.uint32(/* id 26, wireType 2 =*/210).fork()).ldelim(); + if (message.loadBalancerBackendInfo != null && Object.hasOwnProperty.call(message, "loadBalancerBackendInfo")) + $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.encode(message.loadBalancerBackendInfo, writer.uint32(/* id 27, wireType 2 =*/218).fork()).ldelim(); + if (message.storageBucket != null && Object.hasOwnProperty.call(message, "storageBucket")) + $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.encode(message.storageBucket, writer.uint32(/* id 28, wireType 2 =*/226).fork()).ldelim(); + if (message.serverlessNeg != null && Object.hasOwnProperty.call(message, "serverlessNeg")) + $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.encode(message.serverlessNeg, writer.uint32(/* id 29, wireType 2 =*/234).fork()).ldelim(); + if (message.redisInstance != null && Object.hasOwnProperty.call(message, "redisInstance")) + $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.encode(message.redisInstance, writer.uint32(/* id 30, wireType 2 =*/242).fork()).ldelim(); + if (message.redisCluster != null && Object.hasOwnProperty.call(message, "redisCluster")) + $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo.encode(message.redisCluster, writer.uint32(/* id 31, wireType 2 =*/250).fork()).ldelim(); return writer; }; /** - * Encodes the specified NetworkInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.NetworkInfo.verify|verify} messages. + * Encodes the specified Step message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.Step.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static - * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo} message NetworkInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IStep} message Step message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NetworkInfo.encodeDelimited = function encodeDelimited(message, writer) { + Step.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a NetworkInfo message from the specified reader or buffer. + * Decodes a Step message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo + * @returns {google.cloud.networkmanagement.v1beta1.Step} Step * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NetworkInfo.decode = function decode(reader, length) { + Step.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.NetworkInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.Step(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); + message.description = reader.string(); break; } case 2: { - message.uri = reader.string(); + message.state = reader.int32(); + break; + } + case 3: { + message.causesDrop = reader.bool(); break; } case 4: { - message.matchedIpRange = reader.string(); + message.projectId = reader.string(); + break; + } + case 5: { + message.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.decode(reader, reader.uint32()); + break; + } + case 6: { + message.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.decode(reader, reader.uint32()); + break; + } + case 7: { + message.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.decode(reader, reader.uint32()); + break; + } + case 8: { + message.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.decode(reader, reader.uint32()); + break; + } + case 24: { + message.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.decode(reader, reader.uint32()); + break; + } + case 9: { + message.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.decode(reader, reader.uint32()); + break; + } + case 10: { + message.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.decode(reader, reader.uint32()); + break; + } + case 11: { + message.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.decode(reader, reader.uint32()); + break; + } + case 21: { + message.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.decode(reader, reader.uint32()); + break; + } + case 12: { + message.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.decode(reader, reader.uint32()); + break; + } + case 13: { + message.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.decode(reader, reader.uint32()); + break; + } + case 14: { + message.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.decode(reader, reader.uint32()); + break; + } + case 15: { + message.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.decode(reader, reader.uint32()); + break; + } + case 16: { + message.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.decode(reader, reader.uint32()); + break; + } + case 17: { + message.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.decode(reader, reader.uint32()); + break; + } + case 18: { + message.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.decode(reader, reader.uint32()); + break; + } + case 19: { + message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.decode(reader, reader.uint32()); + break; + } + case 30: { + message.redisInstance = $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.decode(reader, reader.uint32()); + break; + } + case 31: { + message.redisCluster = $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo.decode(reader, reader.uint32()); + break; + } + case 20: { + message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.decode(reader, reader.uint32()); + break; + } + case 22: { + message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.decode(reader, reader.uint32()); + break; + } + case 23: { + message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.decode(reader, reader.uint32()); + break; + } + case 25: { + message.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.decode(reader, reader.uint32()); + break; + } + case 26: { + message.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.decode(reader, reader.uint32()); + break; + } + case 27: { + message.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.decode(reader, reader.uint32()); + break; + } + case 28: { + message.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.decode(reader, reader.uint32()); + break; + } + case 29: { + message.serverlessNeg = $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.decode(reader, reader.uint32()); break; } default: @@ -22960,685 +23255,952 @@ }; /** - * Decodes a NetworkInfo message from the specified reader or buffer, length delimited. + * Decodes a Step message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo + * @returns {google.cloud.networkmanagement.v1beta1.Step} Step * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NetworkInfo.decodeDelimited = function decodeDelimited(reader) { + Step.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a NetworkInfo message. + * Verifies a Step message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - NetworkInfo.verify = function verify(message) { + Step.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) - if (!$util.isString(message.matchedIpRange)) - return "matchedIpRange: string expected"; - return null; - }; - - /** - * Creates a NetworkInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo - */ - NetworkInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.NetworkInfo) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.NetworkInfo(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.uri != null) - message.uri = String(object.uri); - if (object.matchedIpRange != null) - message.matchedIpRange = String(object.matchedIpRange); - return message; - }; - - /** - * Creates a plain object from a NetworkInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.NetworkInfo} message NetworkInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - NetworkInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.displayName = ""; - object.uri = ""; - object.matchedIpRange = ""; + var properties = {}; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.state != null && message.hasOwnProperty("state")) + switch (message.state) { + default: + return "state: enum value expected"; + case 0: + case 1: + case 2: + case 27: + case 3: + case 21: + case 22: + case 32: + case 33: + case 23: + case 25: + case 26: + case 29: + case 30: + case 31: + case 4: + case 5: + case 6: + case 7: + case 28: + case 8: + case 9: + case 10: + case 11: + case 12: + case 13: + case 24: + case 14: + case 15: + case 16: + case 17: + case 18: + case 19: + case 20: + break; + } + if (message.causesDrop != null && message.hasOwnProperty("causesDrop")) + if (typeof message.causesDrop !== "boolean") + return "causesDrop: boolean expected"; + if (message.projectId != null && message.hasOwnProperty("projectId")) + if (!$util.isString(message.projectId)) + return "projectId: string expected"; + if (message.instance != null && message.hasOwnProperty("instance")) { + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.verify(message.instance); + if (error) + return "instance." + error; + } } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) - object.matchedIpRange = message.matchedIpRange; - return object; - }; - - /** - * Converts this NetworkInfo to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo - * @instance - * @returns {Object.} JSON object - */ - NetworkInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for NetworkInfo - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - NetworkInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + if (message.firewall != null && message.hasOwnProperty("firewall")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.verify(message.firewall); + if (error) + return "firewall." + error; + } } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.NetworkInfo"; - }; - - return NetworkInfo; - })(); - - v1beta1.FirewallInfo = (function() { - - /** - * Properties of a FirewallInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IFirewallInfo - * @property {string|null} [displayName] FirewallInfo displayName - * @property {string|null} [uri] FirewallInfo uri - * @property {string|null} [direction] FirewallInfo direction - * @property {string|null} [action] FirewallInfo action - * @property {number|null} [priority] FirewallInfo priority - * @property {string|null} [networkUri] FirewallInfo networkUri - * @property {Array.|null} [targetTags] FirewallInfo targetTags - * @property {Array.|null} [targetServiceAccounts] FirewallInfo targetServiceAccounts - * @property {string|null} [policy] FirewallInfo policy - * @property {google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType|null} [firewallRuleType] FirewallInfo firewallRuleType - */ - - /** - * Constructs a new FirewallInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a FirewallInfo. - * @implements IFirewallInfo - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo=} [properties] Properties to set - */ - function FirewallInfo(properties) { - this.targetTags = []; - this.targetServiceAccounts = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * FirewallInfo displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.displayName = ""; - - /** - * FirewallInfo uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.uri = ""; - - /** - * FirewallInfo direction. - * @member {string} direction - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.direction = ""; - - /** - * FirewallInfo action. - * @member {string} action - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.action = ""; - - /** - * FirewallInfo priority. - * @member {number} priority - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.priority = 0; - - /** - * FirewallInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.networkUri = ""; - - /** - * FirewallInfo targetTags. - * @member {Array.} targetTags - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.targetTags = $util.emptyArray; - - /** - * FirewallInfo targetServiceAccounts. - * @member {Array.} targetServiceAccounts - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.targetServiceAccounts = $util.emptyArray; - - /** - * FirewallInfo policy. - * @member {string} policy - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.policy = ""; - - /** - * FirewallInfo firewallRuleType. - * @member {google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType} firewallRuleType - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @instance - */ - FirewallInfo.prototype.firewallRuleType = 0; - - /** - * Creates a new FirewallInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo instance - */ - FirewallInfo.create = function create(properties) { - return new FirewallInfo(properties); - }; - - /** - * Encodes the specified FirewallInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.FirewallInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo} message FirewallInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FirewallInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.direction != null && Object.hasOwnProperty.call(message, "direction")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.direction); - if (message.action != null && Object.hasOwnProperty.call(message, "action")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.action); - if (message.priority != null && Object.hasOwnProperty.call(message, "priority")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.priority); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.networkUri); - if (message.targetTags != null && message.targetTags.length) - for (var i = 0; i < message.targetTags.length; ++i) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.targetTags[i]); - if (message.targetServiceAccounts != null && message.targetServiceAccounts.length) - for (var i = 0; i < message.targetServiceAccounts.length; ++i) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.targetServiceAccounts[i]); - if (message.policy != null && Object.hasOwnProperty.call(message, "policy")) - writer.uint32(/* id 9, wireType 2 =*/74).string(message.policy); - if (message.firewallRuleType != null && Object.hasOwnProperty.call(message, "firewallRuleType")) - writer.uint32(/* id 10, wireType 0 =*/80).int32(message.firewallRuleType); - return writer; - }; - - /** - * Encodes the specified FirewallInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.FirewallInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo} message FirewallInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FirewallInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FirewallInfo message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FirewallInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.FirewallInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - case 2: { - message.uri = reader.string(); - break; - } - case 3: { - message.direction = reader.string(); - break; - } - case 4: { - message.action = reader.string(); - break; - } - case 5: { - message.priority = reader.int32(); - break; - } - case 6: { - message.networkUri = reader.string(); - break; - } - case 7: { - if (!(message.targetTags && message.targetTags.length)) - message.targetTags = []; - message.targetTags.push(reader.string()); - break; - } - case 8: { - if (!(message.targetServiceAccounts && message.targetServiceAccounts.length)) - message.targetServiceAccounts = []; - message.targetServiceAccounts.push(reader.string()); - break; - } - case 9: { - message.policy = reader.string(); - break; - } - case 10: { - message.firewallRuleType = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; + if (message.route != null && message.hasOwnProperty("route")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.verify(message.route); + if (error) + return "route." + error; } } - return message; - }; - - /** - * Decodes a FirewallInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FirewallInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FirewallInfo message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FirewallInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - if (message.direction != null && message.hasOwnProperty("direction")) - if (!$util.isString(message.direction)) - return "direction: string expected"; - if (message.action != null && message.hasOwnProperty("action")) - if (!$util.isString(message.action)) - return "action: string expected"; - if (message.priority != null && message.hasOwnProperty("priority")) - if (!$util.isInteger(message.priority)) - return "priority: integer expected"; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - if (!$util.isString(message.networkUri)) - return "networkUri: string expected"; - if (message.targetTags != null && message.hasOwnProperty("targetTags")) { - if (!Array.isArray(message.targetTags)) - return "targetTags: array expected"; - for (var i = 0; i < message.targetTags.length; ++i) - if (!$util.isString(message.targetTags[i])) - return "targetTags: string[] expected"; + if (message.endpoint != null && message.hasOwnProperty("endpoint")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.verify(message.endpoint); + if (error) + return "endpoint." + error; + } } - if (message.targetServiceAccounts != null && message.hasOwnProperty("targetServiceAccounts")) { - if (!Array.isArray(message.targetServiceAccounts)) - return "targetServiceAccounts: array expected"; - for (var i = 0; i < message.targetServiceAccounts.length; ++i) - if (!$util.isString(message.targetServiceAccounts[i])) - return "targetServiceAccounts: string[] expected"; + if (message.googleService != null && message.hasOwnProperty("googleService")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify(message.googleService); + if (error) + return "googleService." + error; + } } - if (message.policy != null && message.hasOwnProperty("policy")) - if (!$util.isString(message.policy)) - return "policy: string expected"; - if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) - switch (message.firewallRuleType) { - default: - return "firewallRuleType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 100: - case 101: - break; + if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify(message.forwardingRule); + if (error) + return "forwardingRule." + error; } - return null; - }; - - /** - * Creates a FirewallInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo - */ - FirewallInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.FirewallInfo) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.FirewallInfo(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.uri != null) - message.uri = String(object.uri); - if (object.direction != null) - message.direction = String(object.direction); - if (object.action != null) - message.action = String(object.action); - if (object.priority != null) - message.priority = object.priority | 0; - if (object.networkUri != null) - message.networkUri = String(object.networkUri); - if (object.targetTags) { - if (!Array.isArray(object.targetTags)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.FirewallInfo.targetTags: array expected"); - message.targetTags = []; - for (var i = 0; i < object.targetTags.length; ++i) - message.targetTags[i] = String(object.targetTags[i]); } - if (object.targetServiceAccounts) { - if (!Array.isArray(object.targetServiceAccounts)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.FirewallInfo.targetServiceAccounts: array expected"); - message.targetServiceAccounts = []; - for (var i = 0; i < object.targetServiceAccounts.length; ++i) - message.targetServiceAccounts[i] = String(object.targetServiceAccounts[i]); + if (message.vpnGateway != null && message.hasOwnProperty("vpnGateway")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify(message.vpnGateway); + if (error) + return "vpnGateway." + error; + } } - if (object.policy != null) - message.policy = String(object.policy); - switch (object.firewallRuleType) { + if (message.vpnTunnel != null && message.hasOwnProperty("vpnTunnel")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify(message.vpnTunnel); + if (error) + return "vpnTunnel." + error; + } + } + if (message.vpcConnector != null && message.hasOwnProperty("vpcConnector")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.verify(message.vpcConnector); + if (error) + return "vpcConnector." + error; + } + } + if (message.deliver != null && message.hasOwnProperty("deliver")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.verify(message.deliver); + if (error) + return "deliver." + error; + } + } + if (message.forward != null && message.hasOwnProperty("forward")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.verify(message.forward); + if (error) + return "forward." + error; + } + } + if (message.abort != null && message.hasOwnProperty("abort")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.verify(message.abort); + if (error) + return "abort." + error; + } + } + if (message.drop != null && message.hasOwnProperty("drop")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.DropInfo.verify(message.drop); + if (error) + return "drop." + error; + } + } + if (message.loadBalancer != null && message.hasOwnProperty("loadBalancer")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify(message.loadBalancer); + if (error) + return "loadBalancer." + error; + } + } + if (message.network != null && message.hasOwnProperty("network")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.verify(message.network); + if (error) + return "network." + error; + } + } + if (message.gkeMaster != null && message.hasOwnProperty("gkeMaster")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify(message.gkeMaster); + if (error) + return "gkeMaster." + error; + } + } + if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify(message.cloudSqlInstance); + if (error) + return "cloudSqlInstance." + error; + } + } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.verify(message.redisInstance); + if (error) + return "redisInstance." + error; + } + } + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo.verify(message.redisCluster); + if (error) + return "redisCluster." + error; + } + } + if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.verify(message.cloudFunction); + if (error) + return "cloudFunction." + error; + } + } + if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.verify(message.appEngineVersion); + if (error) + return "appEngineVersion." + error; + } + } + if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.verify(message.cloudRunRevision); + if (error) + return "cloudRunRevision." + error; + } + } + if (message.nat != null && message.hasOwnProperty("nat")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.NatInfo.verify(message.nat); + if (error) + return "nat." + error; + } + } + if (message.proxyConnection != null && message.hasOwnProperty("proxyConnection")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.verify(message.proxyConnection); + if (error) + return "proxyConnection." + error; + } + } + if (message.loadBalancerBackendInfo != null && message.hasOwnProperty("loadBalancerBackendInfo")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.verify(message.loadBalancerBackendInfo); + if (error) + return "loadBalancerBackendInfo." + error; + } + } + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.verify(message.storageBucket); + if (error) + return "storageBucket." + error; + } + } + if (message.serverlessNeg != null && message.hasOwnProperty("serverlessNeg")) { + if (properties.stepInfo === 1) + return "stepInfo: multiple values"; + properties.stepInfo = 1; + { + var error = $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.verify(message.serverlessNeg); + if (error) + return "serverlessNeg." + error; + } + } + return null; + }; + + /** + * Creates a Step message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.Step + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.Step} Step + */ + Step.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.Step) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.Step(); + if (object.description != null) + message.description = String(object.description); + switch (object.state) { default: - if (typeof object.firewallRuleType === "number") { - message.firewallRuleType = object.firewallRuleType; + if (typeof object.state === "number") { + message.state = object.state; break; } break; - case "FIREWALL_RULE_TYPE_UNSPECIFIED": + case "STATE_UNSPECIFIED": case 0: - message.firewallRuleType = 0; + message.state = 0; break; - case "HIERARCHICAL_FIREWALL_POLICY_RULE": + case "START_FROM_INSTANCE": case 1: - message.firewallRuleType = 1; + message.state = 1; break; - case "VPC_FIREWALL_RULE": + case "START_FROM_INTERNET": case 2: - message.firewallRuleType = 2; - break; - case "IMPLIED_VPC_FIREWALL_RULE": - case 3: - message.firewallRuleType = 3; + message.state = 2; break; - case "SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE": + case "START_FROM_GOOGLE_SERVICE": + case 27: + message.state = 27; + break; + case "START_FROM_PRIVATE_NETWORK": + case 3: + message.state = 3; + break; + case "START_FROM_GKE_MASTER": + case 21: + message.state = 21; + break; + case "START_FROM_CLOUD_SQL_INSTANCE": + case 22: + message.state = 22; + break; + case "START_FROM_REDIS_INSTANCE": + case 32: + message.state = 32; + break; + case "START_FROM_REDIS_CLUSTER": + case 33: + message.state = 33; + break; + case "START_FROM_CLOUD_FUNCTION": + case 23: + message.state = 23; + break; + case "START_FROM_APP_ENGINE_VERSION": + case 25: + message.state = 25; + break; + case "START_FROM_CLOUD_RUN_REVISION": + case 26: + message.state = 26; + break; + case "START_FROM_STORAGE_BUCKET": + case 29: + message.state = 29; + break; + case "START_FROM_PSC_PUBLISHED_SERVICE": + case 30: + message.state = 30; + break; + case "START_FROM_SERVERLESS_NEG": + case 31: + message.state = 31; + break; + case "APPLY_INGRESS_FIREWALL_RULE": case 4: - message.firewallRuleType = 4; + message.state = 4; break; - case "NETWORK_FIREWALL_POLICY_RULE": + case "APPLY_EGRESS_FIREWALL_RULE": case 5: - message.firewallRuleType = 5; + message.state = 5; break; - case "NETWORK_REGIONAL_FIREWALL_POLICY_RULE": + case "APPLY_ROUTE": case 6: - message.firewallRuleType = 6; + message.state = 6; break; - case "UNSUPPORTED_FIREWALL_POLICY_RULE": - case 100: - message.firewallRuleType = 100; + case "APPLY_FORWARDING_RULE": + case 7: + message.state = 7; break; - case "TRACKING_STATE": - case 101: - message.firewallRuleType = 101; + case "ANALYZE_LOAD_BALANCER_BACKEND": + case 28: + message.state = 28; + break; + case "SPOOFING_APPROVED": + case 8: + message.state = 8; + break; + case "ARRIVE_AT_INSTANCE": + case 9: + message.state = 9; + break; + case "ARRIVE_AT_INTERNAL_LOAD_BALANCER": + case 10: + message.state = 10; + break; + case "ARRIVE_AT_EXTERNAL_LOAD_BALANCER": + case 11: + message.state = 11; + break; + case "ARRIVE_AT_VPN_GATEWAY": + case 12: + message.state = 12; + break; + case "ARRIVE_AT_VPN_TUNNEL": + case 13: + message.state = 13; + break; + case "ARRIVE_AT_VPC_CONNECTOR": + case 24: + message.state = 24; + break; + case "NAT": + case 14: + message.state = 14; + break; + case "PROXY_CONNECTION": + case 15: + message.state = 15; + break; + case "DELIVER": + case 16: + message.state = 16; + break; + case "DROP": + case 17: + message.state = 17; + break; + case "FORWARD": + case 18: + message.state = 18; + break; + case "ABORT": + case 19: + message.state = 19; + break; + case "VIEWER_PERMISSION_MISSING": + case 20: + message.state = 20; break; } + if (object.causesDrop != null) + message.causesDrop = Boolean(object.causesDrop); + if (object.projectId != null) + message.projectId = String(object.projectId); + if (object.instance != null) { + if (typeof object.instance !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.instance: object expected"); + message.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.fromObject(object.instance); + } + if (object.firewall != null) { + if (typeof object.firewall !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.firewall: object expected"); + message.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.fromObject(object.firewall); + } + if (object.route != null) { + if (typeof object.route !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.route: object expected"); + message.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.fromObject(object.route); + } + if (object.endpoint != null) { + if (typeof object.endpoint !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.endpoint: object expected"); + message.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.fromObject(object.endpoint); + } + if (object.googleService != null) { + if (typeof object.googleService !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.googleService: object expected"); + message.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.fromObject(object.googleService); + } + if (object.forwardingRule != null) { + if (typeof object.forwardingRule !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.forwardingRule: object expected"); + message.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.fromObject(object.forwardingRule); + } + if (object.vpnGateway != null) { + if (typeof object.vpnGateway !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpnGateway: object expected"); + message.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.fromObject(object.vpnGateway); + } + if (object.vpnTunnel != null) { + if (typeof object.vpnTunnel !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpnTunnel: object expected"); + message.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.fromObject(object.vpnTunnel); + } + if (object.vpcConnector != null) { + if (typeof object.vpcConnector !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.vpcConnector: object expected"); + message.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.fromObject(object.vpcConnector); + } + if (object.deliver != null) { + if (typeof object.deliver !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.deliver: object expected"); + message.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.fromObject(object.deliver); + } + if (object.forward != null) { + if (typeof object.forward !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.forward: object expected"); + message.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.fromObject(object.forward); + } + if (object.abort != null) { + if (typeof object.abort !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.abort: object expected"); + message.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.fromObject(object.abort); + } + if (object.drop != null) { + if (typeof object.drop !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.drop: object expected"); + message.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.fromObject(object.drop); + } + if (object.loadBalancer != null) { + if (typeof object.loadBalancer !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.loadBalancer: object expected"); + message.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.fromObject(object.loadBalancer); + } + if (object.network != null) { + if (typeof object.network !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.network: object expected"); + message.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.fromObject(object.network); + } + if (object.gkeMaster != null) { + if (typeof object.gkeMaster !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.gkeMaster: object expected"); + message.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.fromObject(object.gkeMaster); + } + if (object.cloudSqlInstance != null) { + if (typeof object.cloudSqlInstance !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudSqlInstance: object expected"); + message.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.fromObject(object.cloudSqlInstance); + } + if (object.redisInstance != null) { + if (typeof object.redisInstance !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.redisInstance: object expected"); + message.redisInstance = $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.fromObject(object.redisInstance); + } + if (object.redisCluster != null) { + if (typeof object.redisCluster !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.redisCluster: object expected"); + message.redisCluster = $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo.fromObject(object.redisCluster); + } + if (object.cloudFunction != null) { + if (typeof object.cloudFunction !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudFunction: object expected"); + message.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.fromObject(object.cloudFunction); + } + if (object.appEngineVersion != null) { + if (typeof object.appEngineVersion !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.appEngineVersion: object expected"); + message.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.fromObject(object.appEngineVersion); + } + if (object.cloudRunRevision != null) { + if (typeof object.cloudRunRevision !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.cloudRunRevision: object expected"); + message.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.fromObject(object.cloudRunRevision); + } + if (object.nat != null) { + if (typeof object.nat !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.nat: object expected"); + message.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.fromObject(object.nat); + } + if (object.proxyConnection != null) { + if (typeof object.proxyConnection !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.proxyConnection: object expected"); + message.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.fromObject(object.proxyConnection); + } + if (object.loadBalancerBackendInfo != null) { + if (typeof object.loadBalancerBackendInfo !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.loadBalancerBackendInfo: object expected"); + message.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.fromObject(object.loadBalancerBackendInfo); + } + if (object.storageBucket != null) { + if (typeof object.storageBucket !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.storageBucket: object expected"); + message.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.fromObject(object.storageBucket); + } + if (object.serverlessNeg != null) { + if (typeof object.serverlessNeg !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.Step.serverlessNeg: object expected"); + message.serverlessNeg = $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.fromObject(object.serverlessNeg); + } return message; }; /** - * Creates a plain object from a FirewallInfo message. Also converts values to other types if specified. + * Creates a plain object from a Step message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static - * @param {google.cloud.networkmanagement.v1beta1.FirewallInfo} message FirewallInfo + * @param {google.cloud.networkmanagement.v1beta1.Step} message Step * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FirewallInfo.toObject = function toObject(message, options) { + Step.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.targetTags = []; - object.targetServiceAccounts = []; - } if (options.defaults) { - object.displayName = ""; - object.uri = ""; - object.direction = ""; - object.action = ""; - object.priority = 0; - object.networkUri = ""; - object.policy = ""; - object.firewallRuleType = options.enums === String ? "FIREWALL_RULE_TYPE_UNSPECIFIED" : 0; + object.description = ""; + object.state = options.enums === String ? "STATE_UNSPECIFIED" : 0; + object.causesDrop = false; + object.projectId = ""; } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - if (message.direction != null && message.hasOwnProperty("direction")) - object.direction = message.direction; - if (message.action != null && message.hasOwnProperty("action")) - object.action = message.action; - if (message.priority != null && message.hasOwnProperty("priority")) - object.priority = message.priority; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - object.networkUri = message.networkUri; - if (message.targetTags && message.targetTags.length) { - object.targetTags = []; - for (var j = 0; j < message.targetTags.length; ++j) - object.targetTags[j] = message.targetTags[j]; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.state != null && message.hasOwnProperty("state")) + object.state = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.Step.State[message.state] === undefined ? message.state : $root.google.cloud.networkmanagement.v1beta1.Step.State[message.state] : message.state; + if (message.causesDrop != null && message.hasOwnProperty("causesDrop")) + object.causesDrop = message.causesDrop; + if (message.projectId != null && message.hasOwnProperty("projectId")) + object.projectId = message.projectId; + if (message.instance != null && message.hasOwnProperty("instance")) { + object.instance = $root.google.cloud.networkmanagement.v1beta1.InstanceInfo.toObject(message.instance, options); + if (options.oneofs) + object.stepInfo = "instance"; } - if (message.targetServiceAccounts && message.targetServiceAccounts.length) { - object.targetServiceAccounts = []; - for (var j = 0; j < message.targetServiceAccounts.length; ++j) - object.targetServiceAccounts[j] = message.targetServiceAccounts[j]; + if (message.firewall != null && message.hasOwnProperty("firewall")) { + object.firewall = $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.toObject(message.firewall, options); + if (options.oneofs) + object.stepInfo = "firewall"; + } + if (message.route != null && message.hasOwnProperty("route")) { + object.route = $root.google.cloud.networkmanagement.v1beta1.RouteInfo.toObject(message.route, options); + if (options.oneofs) + object.stepInfo = "route"; + } + if (message.endpoint != null && message.hasOwnProperty("endpoint")) { + object.endpoint = $root.google.cloud.networkmanagement.v1beta1.EndpointInfo.toObject(message.endpoint, options); + if (options.oneofs) + object.stepInfo = "endpoint"; + } + if (message.forwardingRule != null && message.hasOwnProperty("forwardingRule")) { + object.forwardingRule = $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.toObject(message.forwardingRule, options); + if (options.oneofs) + object.stepInfo = "forwardingRule"; + } + if (message.vpnGateway != null && message.hasOwnProperty("vpnGateway")) { + object.vpnGateway = $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.toObject(message.vpnGateway, options); + if (options.oneofs) + object.stepInfo = "vpnGateway"; + } + if (message.vpnTunnel != null && message.hasOwnProperty("vpnTunnel")) { + object.vpnTunnel = $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.toObject(message.vpnTunnel, options); + if (options.oneofs) + object.stepInfo = "vpnTunnel"; + } + if (message.deliver != null && message.hasOwnProperty("deliver")) { + object.deliver = $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.toObject(message.deliver, options); + if (options.oneofs) + object.stepInfo = "deliver"; + } + if (message.forward != null && message.hasOwnProperty("forward")) { + object.forward = $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.toObject(message.forward, options); + if (options.oneofs) + object.stepInfo = "forward"; + } + if (message.abort != null && message.hasOwnProperty("abort")) { + object.abort = $root.google.cloud.networkmanagement.v1beta1.AbortInfo.toObject(message.abort, options); + if (options.oneofs) + object.stepInfo = "abort"; + } + if (message.drop != null && message.hasOwnProperty("drop")) { + object.drop = $root.google.cloud.networkmanagement.v1beta1.DropInfo.toObject(message.drop, options); + if (options.oneofs) + object.stepInfo = "drop"; + } + if (message.loadBalancer != null && message.hasOwnProperty("loadBalancer")) { + object.loadBalancer = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.toObject(message.loadBalancer, options); + if (options.oneofs) + object.stepInfo = "loadBalancer"; + } + if (message.network != null && message.hasOwnProperty("network")) { + object.network = $root.google.cloud.networkmanagement.v1beta1.NetworkInfo.toObject(message.network, options); + if (options.oneofs) + object.stepInfo = "network"; + } + if (message.gkeMaster != null && message.hasOwnProperty("gkeMaster")) { + object.gkeMaster = $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo.toObject(message.gkeMaster, options); + if (options.oneofs) + object.stepInfo = "gkeMaster"; + } + if (message.cloudSqlInstance != null && message.hasOwnProperty("cloudSqlInstance")) { + object.cloudSqlInstance = $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.toObject(message.cloudSqlInstance, options); + if (options.oneofs) + object.stepInfo = "cloudSqlInstance"; + } + if (message.cloudFunction != null && message.hasOwnProperty("cloudFunction")) { + object.cloudFunction = $root.google.cloud.networkmanagement.v1beta1.CloudFunctionInfo.toObject(message.cloudFunction, options); + if (options.oneofs) + object.stepInfo = "cloudFunction"; + } + if (message.vpcConnector != null && message.hasOwnProperty("vpcConnector")) { + object.vpcConnector = $root.google.cloud.networkmanagement.v1beta1.VpcConnectorInfo.toObject(message.vpcConnector, options); + if (options.oneofs) + object.stepInfo = "vpcConnector"; + } + if (message.appEngineVersion != null && message.hasOwnProperty("appEngineVersion")) { + object.appEngineVersion = $root.google.cloud.networkmanagement.v1beta1.AppEngineVersionInfo.toObject(message.appEngineVersion, options); + if (options.oneofs) + object.stepInfo = "appEngineVersion"; + } + if (message.cloudRunRevision != null && message.hasOwnProperty("cloudRunRevision")) { + object.cloudRunRevision = $root.google.cloud.networkmanagement.v1beta1.CloudRunRevisionInfo.toObject(message.cloudRunRevision, options); + if (options.oneofs) + object.stepInfo = "cloudRunRevision"; + } + if (message.googleService != null && message.hasOwnProperty("googleService")) { + object.googleService = $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.toObject(message.googleService, options); + if (options.oneofs) + object.stepInfo = "googleService"; + } + if (message.nat != null && message.hasOwnProperty("nat")) { + object.nat = $root.google.cloud.networkmanagement.v1beta1.NatInfo.toObject(message.nat, options); + if (options.oneofs) + object.stepInfo = "nat"; + } + if (message.proxyConnection != null && message.hasOwnProperty("proxyConnection")) { + object.proxyConnection = $root.google.cloud.networkmanagement.v1beta1.ProxyConnectionInfo.toObject(message.proxyConnection, options); + if (options.oneofs) + object.stepInfo = "proxyConnection"; + } + if (message.loadBalancerBackendInfo != null && message.hasOwnProperty("loadBalancerBackendInfo")) { + object.loadBalancerBackendInfo = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackendInfo.toObject(message.loadBalancerBackendInfo, options); + if (options.oneofs) + object.stepInfo = "loadBalancerBackendInfo"; + } + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) { + object.storageBucket = $root.google.cloud.networkmanagement.v1beta1.StorageBucketInfo.toObject(message.storageBucket, options); + if (options.oneofs) + object.stepInfo = "storageBucket"; + } + if (message.serverlessNeg != null && message.hasOwnProperty("serverlessNeg")) { + object.serverlessNeg = $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.toObject(message.serverlessNeg, options); + if (options.oneofs) + object.stepInfo = "serverlessNeg"; + } + if (message.redisInstance != null && message.hasOwnProperty("redisInstance")) { + object.redisInstance = $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.toObject(message.redisInstance, options); + if (options.oneofs) + object.stepInfo = "redisInstance"; + } + if (message.redisCluster != null && message.hasOwnProperty("redisCluster")) { + object.redisCluster = $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo.toObject(message.redisCluster, options); + if (options.oneofs) + object.stepInfo = "redisCluster"; } - if (message.policy != null && message.hasOwnProperty("policy")) - object.policy = message.policy; - if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) - object.firewallRuleType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType[message.firewallRuleType] === undefined ? message.firewallRuleType : $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType[message.firewallRuleType] : message.firewallRuleType; return object; }; /** - * Converts this FirewallInfo to JSON. + * Converts this Step to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @instance * @returns {Object.} JSON object */ - FirewallInfo.prototype.toJSON = function toJSON() { + Step.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FirewallInfo + * Gets the default type url for Step * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @memberof google.cloud.networkmanagement.v1beta1.Step * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FirewallInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Step.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.FirewallInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.Step"; }; /** - * FirewallRuleType enum. - * @name google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType + * State enum. + * @name google.cloud.networkmanagement.v1beta1.Step.State * @enum {number} - * @property {number} FIREWALL_RULE_TYPE_UNSPECIFIED=0 FIREWALL_RULE_TYPE_UNSPECIFIED value - * @property {number} HIERARCHICAL_FIREWALL_POLICY_RULE=1 HIERARCHICAL_FIREWALL_POLICY_RULE value - * @property {number} VPC_FIREWALL_RULE=2 VPC_FIREWALL_RULE value - * @property {number} IMPLIED_VPC_FIREWALL_RULE=3 IMPLIED_VPC_FIREWALL_RULE value - * @property {number} SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE=4 SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE value - * @property {number} NETWORK_FIREWALL_POLICY_RULE=5 NETWORK_FIREWALL_POLICY_RULE value - * @property {number} NETWORK_REGIONAL_FIREWALL_POLICY_RULE=6 NETWORK_REGIONAL_FIREWALL_POLICY_RULE value - * @property {number} UNSUPPORTED_FIREWALL_POLICY_RULE=100 UNSUPPORTED_FIREWALL_POLICY_RULE value - * @property {number} TRACKING_STATE=101 TRACKING_STATE value + * @property {number} STATE_UNSPECIFIED=0 STATE_UNSPECIFIED value + * @property {number} START_FROM_INSTANCE=1 START_FROM_INSTANCE value + * @property {number} START_FROM_INTERNET=2 START_FROM_INTERNET value + * @property {number} START_FROM_GOOGLE_SERVICE=27 START_FROM_GOOGLE_SERVICE value + * @property {number} START_FROM_PRIVATE_NETWORK=3 START_FROM_PRIVATE_NETWORK value + * @property {number} START_FROM_GKE_MASTER=21 START_FROM_GKE_MASTER value + * @property {number} START_FROM_CLOUD_SQL_INSTANCE=22 START_FROM_CLOUD_SQL_INSTANCE value + * @property {number} START_FROM_REDIS_INSTANCE=32 START_FROM_REDIS_INSTANCE value + * @property {number} START_FROM_REDIS_CLUSTER=33 START_FROM_REDIS_CLUSTER value + * @property {number} START_FROM_CLOUD_FUNCTION=23 START_FROM_CLOUD_FUNCTION value + * @property {number} START_FROM_APP_ENGINE_VERSION=25 START_FROM_APP_ENGINE_VERSION value + * @property {number} START_FROM_CLOUD_RUN_REVISION=26 START_FROM_CLOUD_RUN_REVISION value + * @property {number} START_FROM_STORAGE_BUCKET=29 START_FROM_STORAGE_BUCKET value + * @property {number} START_FROM_PSC_PUBLISHED_SERVICE=30 START_FROM_PSC_PUBLISHED_SERVICE value + * @property {number} START_FROM_SERVERLESS_NEG=31 START_FROM_SERVERLESS_NEG value + * @property {number} APPLY_INGRESS_FIREWALL_RULE=4 APPLY_INGRESS_FIREWALL_RULE value + * @property {number} APPLY_EGRESS_FIREWALL_RULE=5 APPLY_EGRESS_FIREWALL_RULE value + * @property {number} APPLY_ROUTE=6 APPLY_ROUTE value + * @property {number} APPLY_FORWARDING_RULE=7 APPLY_FORWARDING_RULE value + * @property {number} ANALYZE_LOAD_BALANCER_BACKEND=28 ANALYZE_LOAD_BALANCER_BACKEND value + * @property {number} SPOOFING_APPROVED=8 SPOOFING_APPROVED value + * @property {number} ARRIVE_AT_INSTANCE=9 ARRIVE_AT_INSTANCE value + * @property {number} ARRIVE_AT_INTERNAL_LOAD_BALANCER=10 ARRIVE_AT_INTERNAL_LOAD_BALANCER value + * @property {number} ARRIVE_AT_EXTERNAL_LOAD_BALANCER=11 ARRIVE_AT_EXTERNAL_LOAD_BALANCER value + * @property {number} ARRIVE_AT_VPN_GATEWAY=12 ARRIVE_AT_VPN_GATEWAY value + * @property {number} ARRIVE_AT_VPN_TUNNEL=13 ARRIVE_AT_VPN_TUNNEL value + * @property {number} ARRIVE_AT_VPC_CONNECTOR=24 ARRIVE_AT_VPC_CONNECTOR value + * @property {number} NAT=14 NAT value + * @property {number} PROXY_CONNECTION=15 PROXY_CONNECTION value + * @property {number} DELIVER=16 DELIVER value + * @property {number} DROP=17 DROP value + * @property {number} FORWARD=18 FORWARD value + * @property {number} ABORT=19 ABORT value + * @property {number} VIEWER_PERMISSION_MISSING=20 VIEWER_PERMISSION_MISSING value */ - FirewallInfo.FirewallRuleType = (function() { + Step.State = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "FIREWALL_RULE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "HIERARCHICAL_FIREWALL_POLICY_RULE"] = 1; - values[valuesById[2] = "VPC_FIREWALL_RULE"] = 2; - values[valuesById[3] = "IMPLIED_VPC_FIREWALL_RULE"] = 3; - values[valuesById[4] = "SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE"] = 4; - values[valuesById[5] = "NETWORK_FIREWALL_POLICY_RULE"] = 5; - values[valuesById[6] = "NETWORK_REGIONAL_FIREWALL_POLICY_RULE"] = 6; - values[valuesById[100] = "UNSUPPORTED_FIREWALL_POLICY_RULE"] = 100; - values[valuesById[101] = "TRACKING_STATE"] = 101; - return values; - })(); - - return FirewallInfo; - })(); - - v1beta1.RouteInfo = (function() { - - /** - * Properties of a RouteInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IRouteInfo - * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType|null} [routeType] RouteInfo routeType - * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType|null} [nextHopType] RouteInfo nextHopType - * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope|null} [routeScope] RouteInfo routeScope - * @property {string|null} [displayName] RouteInfo displayName - * @property {string|null} [uri] RouteInfo uri - * @property {string|null} [destIpRange] RouteInfo destIpRange - * @property {string|null} [nextHop] RouteInfo nextHop - * @property {string|null} [networkUri] RouteInfo networkUri - * @property {number|null} [priority] RouteInfo priority - * @property {Array.|null} [instanceTags] RouteInfo instanceTags - * @property {string|null} [srcIpRange] RouteInfo srcIpRange - * @property {Array.|null} [destPortRanges] RouteInfo destPortRanges - * @property {Array.|null} [srcPortRanges] RouteInfo srcPortRanges - * @property {Array.|null} [protocols] RouteInfo protocols - * @property {string|null} [nccHubUri] RouteInfo nccHubUri - * @property {string|null} [nccSpokeUri] RouteInfo nccSpokeUri + values[valuesById[0] = "STATE_UNSPECIFIED"] = 0; + values[valuesById[1] = "START_FROM_INSTANCE"] = 1; + values[valuesById[2] = "START_FROM_INTERNET"] = 2; + values[valuesById[27] = "START_FROM_GOOGLE_SERVICE"] = 27; + values[valuesById[3] = "START_FROM_PRIVATE_NETWORK"] = 3; + values[valuesById[21] = "START_FROM_GKE_MASTER"] = 21; + values[valuesById[22] = "START_FROM_CLOUD_SQL_INSTANCE"] = 22; + values[valuesById[32] = "START_FROM_REDIS_INSTANCE"] = 32; + values[valuesById[33] = "START_FROM_REDIS_CLUSTER"] = 33; + values[valuesById[23] = "START_FROM_CLOUD_FUNCTION"] = 23; + values[valuesById[25] = "START_FROM_APP_ENGINE_VERSION"] = 25; + values[valuesById[26] = "START_FROM_CLOUD_RUN_REVISION"] = 26; + values[valuesById[29] = "START_FROM_STORAGE_BUCKET"] = 29; + values[valuesById[30] = "START_FROM_PSC_PUBLISHED_SERVICE"] = 30; + values[valuesById[31] = "START_FROM_SERVERLESS_NEG"] = 31; + values[valuesById[4] = "APPLY_INGRESS_FIREWALL_RULE"] = 4; + values[valuesById[5] = "APPLY_EGRESS_FIREWALL_RULE"] = 5; + values[valuesById[6] = "APPLY_ROUTE"] = 6; + values[valuesById[7] = "APPLY_FORWARDING_RULE"] = 7; + values[valuesById[28] = "ANALYZE_LOAD_BALANCER_BACKEND"] = 28; + values[valuesById[8] = "SPOOFING_APPROVED"] = 8; + values[valuesById[9] = "ARRIVE_AT_INSTANCE"] = 9; + values[valuesById[10] = "ARRIVE_AT_INTERNAL_LOAD_BALANCER"] = 10; + values[valuesById[11] = "ARRIVE_AT_EXTERNAL_LOAD_BALANCER"] = 11; + values[valuesById[12] = "ARRIVE_AT_VPN_GATEWAY"] = 12; + values[valuesById[13] = "ARRIVE_AT_VPN_TUNNEL"] = 13; + values[valuesById[24] = "ARRIVE_AT_VPC_CONNECTOR"] = 24; + values[valuesById[14] = "NAT"] = 14; + values[valuesById[15] = "PROXY_CONNECTION"] = 15; + values[valuesById[16] = "DELIVER"] = 16; + values[valuesById[17] = "DROP"] = 17; + values[valuesById[18] = "FORWARD"] = 18; + values[valuesById[19] = "ABORT"] = 19; + values[valuesById[20] = "VIEWER_PERMISSION_MISSING"] = 20; + return values; + })(); + + return Step; + })(); + + v1beta1.InstanceInfo = (function() { + + /** + * Properties of an InstanceInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IInstanceInfo + * @property {string|null} [displayName] InstanceInfo displayName + * @property {string|null} [uri] InstanceInfo uri + * @property {string|null} ["interface"] InstanceInfo interface + * @property {string|null} [networkUri] InstanceInfo networkUri + * @property {string|null} [internalIp] InstanceInfo internalIp + * @property {string|null} [externalIp] InstanceInfo externalIp + * @property {Array.|null} [networkTags] InstanceInfo networkTags + * @property {string|null} [serviceAccount] InstanceInfo serviceAccount + * @property {string|null} [pscNetworkAttachmentUri] InstanceInfo pscNetworkAttachmentUri */ /** - * Constructs a new RouteInfo. + * Constructs a new InstanceInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a RouteInfo. - * @implements IRouteInfo + * @classdesc Represents an InstanceInfo. + * @implements IInstanceInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo=} [properties] Properties to set */ - function RouteInfo(properties) { - this.instanceTags = []; - this.destPortRanges = []; - this.srcPortRanges = []; - this.protocols = []; + function InstanceInfo(properties) { + this.networkTags = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -23646,264 +24208,154 @@ } /** - * RouteInfo routeType. - * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType} routeType - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.routeType = 0; - - /** - * RouteInfo nextHopType. - * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType} nextHopType - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.nextHopType = 0; - - /** - * RouteInfo routeScope. - * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope} routeScope - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.routeScope = 0; - - /** - * RouteInfo displayName. + * InstanceInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.displayName = ""; + InstanceInfo.prototype.displayName = ""; /** - * RouteInfo uri. + * InstanceInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.uri = ""; - - /** - * RouteInfo destIpRange. - * @member {string} destIpRange - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.destIpRange = ""; + InstanceInfo.prototype.uri = ""; /** - * RouteInfo nextHop. - * @member {string} nextHop - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo interface. + * @member {string} interface + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.nextHop = ""; + InstanceInfo.prototype["interface"] = ""; /** - * RouteInfo networkUri. + * InstanceInfo networkUri. * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.networkUri = ""; - - /** - * RouteInfo priority. - * @member {number} priority - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.priority = 0; - - /** - * RouteInfo instanceTags. - * @member {Array.} instanceTags - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.instanceTags = $util.emptyArray; - - /** - * RouteInfo srcIpRange. - * @member {string} srcIpRange - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.srcIpRange = ""; - - /** - * RouteInfo destPortRanges. - * @member {Array.} destPortRanges - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo - * @instance - */ - RouteInfo.prototype.destPortRanges = $util.emptyArray; - - /** - * RouteInfo srcPortRanges. - * @member {Array.} srcPortRanges - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.srcPortRanges = $util.emptyArray; + InstanceInfo.prototype.networkUri = ""; /** - * RouteInfo protocols. - * @member {Array.} protocols - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo internalIp. + * @member {string} internalIp + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.protocols = $util.emptyArray; + InstanceInfo.prototype.internalIp = ""; /** - * RouteInfo nccHubUri. - * @member {string|null|undefined} nccHubUri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo externalIp. + * @member {string} externalIp + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.nccHubUri = null; + InstanceInfo.prototype.externalIp = ""; /** - * RouteInfo nccSpokeUri. - * @member {string|null|undefined} nccSpokeUri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo networkTags. + * @member {Array.} networkTags + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - RouteInfo.prototype.nccSpokeUri = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + InstanceInfo.prototype.networkTags = $util.emptyArray; /** - * RouteInfo _nccHubUri. - * @member {"nccHubUri"|undefined} _nccHubUri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo serviceAccount. + * @member {string} serviceAccount + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - Object.defineProperty(RouteInfo.prototype, "_nccHubUri", { - get: $util.oneOfGetter($oneOfFields = ["nccHubUri"]), - set: $util.oneOfSetter($oneOfFields) - }); + InstanceInfo.prototype.serviceAccount = ""; /** - * RouteInfo _nccSpokeUri. - * @member {"nccSpokeUri"|undefined} _nccSpokeUri - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * InstanceInfo pscNetworkAttachmentUri. + * @member {string} pscNetworkAttachmentUri + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance */ - Object.defineProperty(RouteInfo.prototype, "_nccSpokeUri", { - get: $util.oneOfGetter($oneOfFields = ["nccSpokeUri"]), - set: $util.oneOfSetter($oneOfFields) - }); + InstanceInfo.prototype.pscNetworkAttachmentUri = ""; /** - * Creates a new RouteInfo instance using the specified properties. + * Creates a new InstanceInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo instance */ - RouteInfo.create = function create(properties) { - return new RouteInfo(properties); + InstanceInfo.create = function create(properties) { + return new InstanceInfo(properties); }; /** - * Encodes the specified RouteInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RouteInfo.verify|verify} messages. + * Encodes the specified InstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.InstanceInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo} message RouteInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo} message InstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RouteInfo.encode = function encode(message, writer) { + InstanceInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.destIpRange != null && Object.hasOwnProperty.call(message, "destIpRange")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.destIpRange); - if (message.nextHop != null && Object.hasOwnProperty.call(message, "nextHop")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.nextHop); + if (message["interface"] != null && Object.hasOwnProperty.call(message, "interface")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message["interface"]); if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.networkUri); - if (message.priority != null && Object.hasOwnProperty.call(message, "priority")) - writer.uint32(/* id 6, wireType 0 =*/48).int32(message.priority); - if (message.instanceTags != null && message.instanceTags.length) - for (var i = 0; i < message.instanceTags.length; ++i) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.instanceTags[i]); - if (message.routeType != null && Object.hasOwnProperty.call(message, "routeType")) - writer.uint32(/* id 8, wireType 0 =*/64).int32(message.routeType); - if (message.nextHopType != null && Object.hasOwnProperty.call(message, "nextHopType")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.nextHopType); - if (message.srcIpRange != null && Object.hasOwnProperty.call(message, "srcIpRange")) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.srcIpRange); - if (message.destPortRanges != null && message.destPortRanges.length) - for (var i = 0; i < message.destPortRanges.length; ++i) - writer.uint32(/* id 11, wireType 2 =*/90).string(message.destPortRanges[i]); - if (message.srcPortRanges != null && message.srcPortRanges.length) - for (var i = 0; i < message.srcPortRanges.length; ++i) - writer.uint32(/* id 12, wireType 2 =*/98).string(message.srcPortRanges[i]); - if (message.protocols != null && message.protocols.length) - for (var i = 0; i < message.protocols.length; ++i) - writer.uint32(/* id 13, wireType 2 =*/106).string(message.protocols[i]); - if (message.routeScope != null && Object.hasOwnProperty.call(message, "routeScope")) - writer.uint32(/* id 14, wireType 0 =*/112).int32(message.routeScope); - if (message.nccHubUri != null && Object.hasOwnProperty.call(message, "nccHubUri")) - writer.uint32(/* id 15, wireType 2 =*/122).string(message.nccHubUri); - if (message.nccSpokeUri != null && Object.hasOwnProperty.call(message, "nccSpokeUri")) - writer.uint32(/* id 16, wireType 2 =*/130).string(message.nccSpokeUri); + writer.uint32(/* id 4, wireType 2 =*/34).string(message.networkUri); + if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); + if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); + if (message.networkTags != null && message.networkTags.length) + for (var i = 0; i < message.networkTags.length; ++i) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkTags[i]); + if (message.serviceAccount != null && Object.hasOwnProperty.call(message, "serviceAccount")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.serviceAccount); + if (message.pscNetworkAttachmentUri != null && Object.hasOwnProperty.call(message, "pscNetworkAttachmentUri")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.pscNetworkAttachmentUri); return writer; }; /** - * Encodes the specified RouteInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RouteInfo.verify|verify} messages. + * Encodes the specified InstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.InstanceInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo} message RouteInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IInstanceInfo} message InstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RouteInfo.encodeDelimited = function encodeDelimited(message, writer) { + InstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a RouteInfo message from the specified reader or buffer. + * Decodes an InstanceInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo + * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RouteInfo.decode = function decode(reader, length) { + InstanceInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.RouteInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.InstanceInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 8: { - message.routeType = reader.int32(); - break; - } - case 9: { - message.nextHopType = reader.int32(); - break; - } - case 14: { - message.routeScope = reader.int32(); - break; - } case 1: { message.displayName = reader.string(); break; @@ -23913,55 +24365,33 @@ break; } case 3: { - message.destIpRange = reader.string(); + message["interface"] = reader.string(); break; } case 4: { - message.nextHop = reader.string(); + message.networkUri = reader.string(); break; } case 5: { - message.networkUri = reader.string(); + message.internalIp = reader.string(); break; } case 6: { - message.priority = reader.int32(); + message.externalIp = reader.string(); break; } case 7: { - if (!(message.instanceTags && message.instanceTags.length)) - message.instanceTags = []; - message.instanceTags.push(reader.string()); - break; - } - case 10: { - message.srcIpRange = reader.string(); - break; - } - case 11: { - if (!(message.destPortRanges && message.destPortRanges.length)) - message.destPortRanges = []; - message.destPortRanges.push(reader.string()); - break; - } - case 12: { - if (!(message.srcPortRanges && message.srcPortRanges.length)) - message.srcPortRanges = []; - message.srcPortRanges.push(reader.string()); - break; - } - case 13: { - if (!(message.protocols && message.protocols.length)) - message.protocols = []; - message.protocols.push(reader.string()); + if (!(message.networkTags && message.networkTags.length)) + message.networkTags = []; + message.networkTags.push(reader.string()); break; } - case 15: { - message.nccHubUri = reader.string(); + case 8: { + message.serviceAccount = reader.string(); break; } - case 16: { - message.nccSpokeUri = reader.string(); + case 9: { + message.pscNetworkAttachmentUri = reader.string(); break; } default: @@ -23973,528 +24403,204 @@ }; /** - * Decodes a RouteInfo message from the specified reader or buffer, length delimited. + * Decodes an InstanceInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo + * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RouteInfo.decodeDelimited = function decodeDelimited(reader) { + InstanceInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a RouteInfo message. + * Verifies an InstanceInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - RouteInfo.verify = function verify(message) { + InstanceInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.routeType != null && message.hasOwnProperty("routeType")) - switch (message.routeType) { - default: - return "routeType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - break; - } - if (message.nextHopType != null && message.hasOwnProperty("nextHopType")) - switch (message.nextHopType) { - default: - return "nextHopType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - case 10: - case 11: - case 12: - break; - } - if (message.routeScope != null && message.hasOwnProperty("routeScope")) - switch (message.routeScope) { - default: - return "routeScope: enum value expected"; - case 0: - case 1: - case 2: - break; - } if (message.displayName != null && message.hasOwnProperty("displayName")) if (!$util.isString(message.displayName)) return "displayName: string expected"; if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; - if (message.destIpRange != null && message.hasOwnProperty("destIpRange")) - if (!$util.isString(message.destIpRange)) - return "destIpRange: string expected"; - if (message.nextHop != null && message.hasOwnProperty("nextHop")) - if (!$util.isString(message.nextHop)) - return "nextHop: string expected"; + if (message["interface"] != null && message.hasOwnProperty("interface")) + if (!$util.isString(message["interface"])) + return "interface: string expected"; if (message.networkUri != null && message.hasOwnProperty("networkUri")) if (!$util.isString(message.networkUri)) return "networkUri: string expected"; - if (message.priority != null && message.hasOwnProperty("priority")) - if (!$util.isInteger(message.priority)) - return "priority: integer expected"; - if (message.instanceTags != null && message.hasOwnProperty("instanceTags")) { - if (!Array.isArray(message.instanceTags)) - return "instanceTags: array expected"; - for (var i = 0; i < message.instanceTags.length; ++i) - if (!$util.isString(message.instanceTags[i])) - return "instanceTags: string[] expected"; - } - if (message.srcIpRange != null && message.hasOwnProperty("srcIpRange")) - if (!$util.isString(message.srcIpRange)) - return "srcIpRange: string expected"; - if (message.destPortRanges != null && message.hasOwnProperty("destPortRanges")) { - if (!Array.isArray(message.destPortRanges)) - return "destPortRanges: array expected"; - for (var i = 0; i < message.destPortRanges.length; ++i) - if (!$util.isString(message.destPortRanges[i])) - return "destPortRanges: string[] expected"; - } - if (message.srcPortRanges != null && message.hasOwnProperty("srcPortRanges")) { - if (!Array.isArray(message.srcPortRanges)) - return "srcPortRanges: array expected"; - for (var i = 0; i < message.srcPortRanges.length; ++i) - if (!$util.isString(message.srcPortRanges[i])) - return "srcPortRanges: string[] expected"; - } - if (message.protocols != null && message.hasOwnProperty("protocols")) { - if (!Array.isArray(message.protocols)) - return "protocols: array expected"; - for (var i = 0; i < message.protocols.length; ++i) - if (!$util.isString(message.protocols[i])) - return "protocols: string[] expected"; - } - if (message.nccHubUri != null && message.hasOwnProperty("nccHubUri")) { - properties._nccHubUri = 1; - if (!$util.isString(message.nccHubUri)) - return "nccHubUri: string expected"; - } - if (message.nccSpokeUri != null && message.hasOwnProperty("nccSpokeUri")) { - properties._nccSpokeUri = 1; - if (!$util.isString(message.nccSpokeUri)) - return "nccSpokeUri: string expected"; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + if (!$util.isString(message.internalIp)) + return "internalIp: string expected"; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + if (!$util.isString(message.externalIp)) + return "externalIp: string expected"; + if (message.networkTags != null && message.hasOwnProperty("networkTags")) { + if (!Array.isArray(message.networkTags)) + return "networkTags: array expected"; + for (var i = 0; i < message.networkTags.length; ++i) + if (!$util.isString(message.networkTags[i])) + return "networkTags: string[] expected"; } + if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) + if (!$util.isString(message.serviceAccount)) + return "serviceAccount: string expected"; + if (message.pscNetworkAttachmentUri != null && message.hasOwnProperty("pscNetworkAttachmentUri")) + if (!$util.isString(message.pscNetworkAttachmentUri)) + return "pscNetworkAttachmentUri: string expected"; return null; }; /** - * Creates a RouteInfo message from a plain object. Also converts values to their respective internal types. + * Creates an InstanceInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo + * @returns {google.cloud.networkmanagement.v1beta1.InstanceInfo} InstanceInfo */ - RouteInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.RouteInfo) + InstanceInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.InstanceInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.RouteInfo(); - switch (object.routeType) { - default: - if (typeof object.routeType === "number") { - message.routeType = object.routeType; - break; - } - break; - case "ROUTE_TYPE_UNSPECIFIED": - case 0: - message.routeType = 0; - break; - case "SUBNET": - case 1: - message.routeType = 1; - break; - case "STATIC": - case 2: - message.routeType = 2; - break; - case "DYNAMIC": - case 3: - message.routeType = 3; - break; - case "PEERING_SUBNET": - case 4: - message.routeType = 4; - break; - case "PEERING_STATIC": - case 5: - message.routeType = 5; - break; - case "PEERING_DYNAMIC": - case 6: - message.routeType = 6; - break; - case "POLICY_BASED": - case 7: - message.routeType = 7; - break; - } - switch (object.nextHopType) { - default: - if (typeof object.nextHopType === "number") { - message.nextHopType = object.nextHopType; - break; - } - break; - case "NEXT_HOP_TYPE_UNSPECIFIED": - case 0: - message.nextHopType = 0; - break; - case "NEXT_HOP_IP": - case 1: - message.nextHopType = 1; - break; - case "NEXT_HOP_INSTANCE": - case 2: - message.nextHopType = 2; - break; - case "NEXT_HOP_NETWORK": - case 3: - message.nextHopType = 3; - break; - case "NEXT_HOP_PEERING": - case 4: - message.nextHopType = 4; - break; - case "NEXT_HOP_INTERCONNECT": - case 5: - message.nextHopType = 5; - break; - case "NEXT_HOP_VPN_TUNNEL": - case 6: - message.nextHopType = 6; - break; - case "NEXT_HOP_VPN_GATEWAY": - case 7: - message.nextHopType = 7; - break; - case "NEXT_HOP_INTERNET_GATEWAY": - case 8: - message.nextHopType = 8; - break; - case "NEXT_HOP_BLACKHOLE": - case 9: - message.nextHopType = 9; - break; - case "NEXT_HOP_ILB": - case 10: - message.nextHopType = 10; - break; - case "NEXT_HOP_ROUTER_APPLIANCE": - case 11: - message.nextHopType = 11; - break; - case "NEXT_HOP_NCC_HUB": - case 12: - message.nextHopType = 12; - break; - } - switch (object.routeScope) { - default: - if (typeof object.routeScope === "number") { - message.routeScope = object.routeScope; - break; - } - break; - case "ROUTE_SCOPE_UNSPECIFIED": - case 0: - message.routeScope = 0; - break; - case "NETWORK": - case 1: - message.routeScope = 1; - break; - case "NCC_HUB": - case 2: - message.routeScope = 2; - break; - } + var message = new $root.google.cloud.networkmanagement.v1beta1.InstanceInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); - if (object.destIpRange != null) - message.destIpRange = String(object.destIpRange); - if (object.nextHop != null) - message.nextHop = String(object.nextHop); + if (object["interface"] != null) + message["interface"] = String(object["interface"]); if (object.networkUri != null) message.networkUri = String(object.networkUri); - if (object.priority != null) - message.priority = object.priority | 0; - if (object.instanceTags) { - if (!Array.isArray(object.instanceTags)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.instanceTags: array expected"); - message.instanceTags = []; - for (var i = 0; i < object.instanceTags.length; ++i) - message.instanceTags[i] = String(object.instanceTags[i]); - } - if (object.srcIpRange != null) - message.srcIpRange = String(object.srcIpRange); - if (object.destPortRanges) { - if (!Array.isArray(object.destPortRanges)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.destPortRanges: array expected"); - message.destPortRanges = []; - for (var i = 0; i < object.destPortRanges.length; ++i) - message.destPortRanges[i] = String(object.destPortRanges[i]); - } - if (object.srcPortRanges) { - if (!Array.isArray(object.srcPortRanges)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.srcPortRanges: array expected"); - message.srcPortRanges = []; - for (var i = 0; i < object.srcPortRanges.length; ++i) - message.srcPortRanges[i] = String(object.srcPortRanges[i]); - } - if (object.protocols) { - if (!Array.isArray(object.protocols)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.protocols: array expected"); - message.protocols = []; - for (var i = 0; i < object.protocols.length; ++i) - message.protocols[i] = String(object.protocols[i]); + if (object.internalIp != null) + message.internalIp = String(object.internalIp); + if (object.externalIp != null) + message.externalIp = String(object.externalIp); + if (object.networkTags) { + if (!Array.isArray(object.networkTags)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.InstanceInfo.networkTags: array expected"); + message.networkTags = []; + for (var i = 0; i < object.networkTags.length; ++i) + message.networkTags[i] = String(object.networkTags[i]); } - if (object.nccHubUri != null) - message.nccHubUri = String(object.nccHubUri); - if (object.nccSpokeUri != null) - message.nccSpokeUri = String(object.nccSpokeUri); + if (object.serviceAccount != null) + message.serviceAccount = String(object.serviceAccount); + if (object.pscNetworkAttachmentUri != null) + message.pscNetworkAttachmentUri = String(object.pscNetworkAttachmentUri); return message; }; /** - * Creates a plain object from a RouteInfo message. Also converts values to other types if specified. + * Creates a plain object from an InstanceInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.RouteInfo} message RouteInfo + * @param {google.cloud.networkmanagement.v1beta1.InstanceInfo} message InstanceInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - RouteInfo.toObject = function toObject(message, options) { + InstanceInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.instanceTags = []; - object.destPortRanges = []; - object.srcPortRanges = []; - object.protocols = []; - } + if (options.arrays || options.defaults) + object.networkTags = []; if (options.defaults) { object.displayName = ""; object.uri = ""; - object.destIpRange = ""; - object.nextHop = ""; + object["interface"] = ""; object.networkUri = ""; - object.priority = 0; - object.routeType = options.enums === String ? "ROUTE_TYPE_UNSPECIFIED" : 0; - object.nextHopType = options.enums === String ? "NEXT_HOP_TYPE_UNSPECIFIED" : 0; - object.srcIpRange = ""; - object.routeScope = options.enums === String ? "ROUTE_SCOPE_UNSPECIFIED" : 0; + object.internalIp = ""; + object.externalIp = ""; + object.serviceAccount = ""; + object.pscNetworkAttachmentUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.destIpRange != null && message.hasOwnProperty("destIpRange")) - object.destIpRange = message.destIpRange; - if (message.nextHop != null && message.hasOwnProperty("nextHop")) - object.nextHop = message.nextHop; + if (message["interface"] != null && message.hasOwnProperty("interface")) + object["interface"] = message["interface"]; if (message.networkUri != null && message.hasOwnProperty("networkUri")) object.networkUri = message.networkUri; - if (message.priority != null && message.hasOwnProperty("priority")) - object.priority = message.priority; - if (message.instanceTags && message.instanceTags.length) { - object.instanceTags = []; - for (var j = 0; j < message.instanceTags.length; ++j) - object.instanceTags[j] = message.instanceTags[j]; - } - if (message.routeType != null && message.hasOwnProperty("routeType")) - object.routeType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType[message.routeType] === undefined ? message.routeType : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType[message.routeType] : message.routeType; - if (message.nextHopType != null && message.hasOwnProperty("nextHopType")) - object.nextHopType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType[message.nextHopType] === undefined ? message.nextHopType : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType[message.nextHopType] : message.nextHopType; - if (message.srcIpRange != null && message.hasOwnProperty("srcIpRange")) - object.srcIpRange = message.srcIpRange; - if (message.destPortRanges && message.destPortRanges.length) { - object.destPortRanges = []; - for (var j = 0; j < message.destPortRanges.length; ++j) - object.destPortRanges[j] = message.destPortRanges[j]; - } - if (message.srcPortRanges && message.srcPortRanges.length) { - object.srcPortRanges = []; - for (var j = 0; j < message.srcPortRanges.length; ++j) - object.srcPortRanges[j] = message.srcPortRanges[j]; - } - if (message.protocols && message.protocols.length) { - object.protocols = []; - for (var j = 0; j < message.protocols.length; ++j) - object.protocols[j] = message.protocols[j]; - } - if (message.routeScope != null && message.hasOwnProperty("routeScope")) - object.routeScope = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope[message.routeScope] === undefined ? message.routeScope : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope[message.routeScope] : message.routeScope; - if (message.nccHubUri != null && message.hasOwnProperty("nccHubUri")) { - object.nccHubUri = message.nccHubUri; - if (options.oneofs) - object._nccHubUri = "nccHubUri"; - } - if (message.nccSpokeUri != null && message.hasOwnProperty("nccSpokeUri")) { - object.nccSpokeUri = message.nccSpokeUri; - if (options.oneofs) - object._nccSpokeUri = "nccSpokeUri"; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + object.internalIp = message.internalIp; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + object.externalIp = message.externalIp; + if (message.networkTags && message.networkTags.length) { + object.networkTags = []; + for (var j = 0; j < message.networkTags.length; ++j) + object.networkTags[j] = message.networkTags[j]; } + if (message.serviceAccount != null && message.hasOwnProperty("serviceAccount")) + object.serviceAccount = message.serviceAccount; + if (message.pscNetworkAttachmentUri != null && message.hasOwnProperty("pscNetworkAttachmentUri")) + object.pscNetworkAttachmentUri = message.pscNetworkAttachmentUri; return object; }; /** - * Converts this RouteInfo to JSON. + * Converts this InstanceInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @instance * @returns {Object.} JSON object */ - RouteInfo.prototype.toJSON = function toJSON() { + InstanceInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for RouteInfo + * Gets the default type url for InstanceInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @memberof google.cloud.networkmanagement.v1beta1.InstanceInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - RouteInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + InstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.RouteInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.InstanceInfo"; }; - /** - * RouteType enum. - * @name google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType - * @enum {number} - * @property {number} ROUTE_TYPE_UNSPECIFIED=0 ROUTE_TYPE_UNSPECIFIED value - * @property {number} SUBNET=1 SUBNET value - * @property {number} STATIC=2 STATIC value - * @property {number} DYNAMIC=3 DYNAMIC value - * @property {number} PEERING_SUBNET=4 PEERING_SUBNET value - * @property {number} PEERING_STATIC=5 PEERING_STATIC value - * @property {number} PEERING_DYNAMIC=6 PEERING_DYNAMIC value - * @property {number} POLICY_BASED=7 POLICY_BASED value - */ - RouteInfo.RouteType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ROUTE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "SUBNET"] = 1; - values[valuesById[2] = "STATIC"] = 2; - values[valuesById[3] = "DYNAMIC"] = 3; - values[valuesById[4] = "PEERING_SUBNET"] = 4; - values[valuesById[5] = "PEERING_STATIC"] = 5; - values[valuesById[6] = "PEERING_DYNAMIC"] = 6; - values[valuesById[7] = "POLICY_BASED"] = 7; - return values; - })(); - - /** - * NextHopType enum. - * @name google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType - * @enum {number} - * @property {number} NEXT_HOP_TYPE_UNSPECIFIED=0 NEXT_HOP_TYPE_UNSPECIFIED value - * @property {number} NEXT_HOP_IP=1 NEXT_HOP_IP value - * @property {number} NEXT_HOP_INSTANCE=2 NEXT_HOP_INSTANCE value - * @property {number} NEXT_HOP_NETWORK=3 NEXT_HOP_NETWORK value - * @property {number} NEXT_HOP_PEERING=4 NEXT_HOP_PEERING value - * @property {number} NEXT_HOP_INTERCONNECT=5 NEXT_HOP_INTERCONNECT value - * @property {number} NEXT_HOP_VPN_TUNNEL=6 NEXT_HOP_VPN_TUNNEL value - * @property {number} NEXT_HOP_VPN_GATEWAY=7 NEXT_HOP_VPN_GATEWAY value - * @property {number} NEXT_HOP_INTERNET_GATEWAY=8 NEXT_HOP_INTERNET_GATEWAY value - * @property {number} NEXT_HOP_BLACKHOLE=9 NEXT_HOP_BLACKHOLE value - * @property {number} NEXT_HOP_ILB=10 NEXT_HOP_ILB value - * @property {number} NEXT_HOP_ROUTER_APPLIANCE=11 NEXT_HOP_ROUTER_APPLIANCE value - * @property {number} NEXT_HOP_NCC_HUB=12 NEXT_HOP_NCC_HUB value - */ - RouteInfo.NextHopType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "NEXT_HOP_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "NEXT_HOP_IP"] = 1; - values[valuesById[2] = "NEXT_HOP_INSTANCE"] = 2; - values[valuesById[3] = "NEXT_HOP_NETWORK"] = 3; - values[valuesById[4] = "NEXT_HOP_PEERING"] = 4; - values[valuesById[5] = "NEXT_HOP_INTERCONNECT"] = 5; - values[valuesById[6] = "NEXT_HOP_VPN_TUNNEL"] = 6; - values[valuesById[7] = "NEXT_HOP_VPN_GATEWAY"] = 7; - values[valuesById[8] = "NEXT_HOP_INTERNET_GATEWAY"] = 8; - values[valuesById[9] = "NEXT_HOP_BLACKHOLE"] = 9; - values[valuesById[10] = "NEXT_HOP_ILB"] = 10; - values[valuesById[11] = "NEXT_HOP_ROUTER_APPLIANCE"] = 11; - values[valuesById[12] = "NEXT_HOP_NCC_HUB"] = 12; - return values; - })(); - - /** - * RouteScope enum. - * @name google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope - * @enum {number} - * @property {number} ROUTE_SCOPE_UNSPECIFIED=0 ROUTE_SCOPE_UNSPECIFIED value - * @property {number} NETWORK=1 NETWORK value - * @property {number} NCC_HUB=2 NCC_HUB value - */ - RouteInfo.RouteScope = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ROUTE_SCOPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "NETWORK"] = 1; - values[valuesById[2] = "NCC_HUB"] = 2; - return values; - })(); - - return RouteInfo; + return InstanceInfo; })(); - v1beta1.GoogleServiceInfo = (function() { + v1beta1.NetworkInfo = (function() { /** - * Properties of a GoogleServiceInfo. + * Properties of a NetworkInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IGoogleServiceInfo - * @property {string|null} [sourceIp] GoogleServiceInfo sourceIp - * @property {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType|null} [googleServiceType] GoogleServiceInfo googleServiceType + * @interface INetworkInfo + * @property {string|null} [displayName] NetworkInfo displayName + * @property {string|null} [uri] NetworkInfo uri + * @property {string|null} [matchedSubnetUri] NetworkInfo matchedSubnetUri + * @property {string|null} [matchedIpRange] NetworkInfo matchedIpRange + * @property {string|null} [region] NetworkInfo region */ /** - * Constructs a new GoogleServiceInfo. + * Constructs a new NetworkInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a GoogleServiceInfo. - * @implements IGoogleServiceInfo + * @classdesc Represents a NetworkInfo. + * @implements INetworkInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo=} [properties] Properties to set */ - function GoogleServiceInfo(properties) { + function NetworkInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -24502,89 +24608,131 @@ } /** - * GoogleServiceInfo sourceIp. - * @member {string} sourceIp - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * NetworkInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @instance */ - GoogleServiceInfo.prototype.sourceIp = ""; + NetworkInfo.prototype.displayName = ""; /** - * GoogleServiceInfo googleServiceType. - * @member {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType} googleServiceType - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * NetworkInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @instance */ - GoogleServiceInfo.prototype.googleServiceType = 0; + NetworkInfo.prototype.uri = ""; /** - * Creates a new GoogleServiceInfo instance using the specified properties. + * NetworkInfo matchedSubnetUri. + * @member {string} matchedSubnetUri + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @instance + */ + NetworkInfo.prototype.matchedSubnetUri = ""; + + /** + * NetworkInfo matchedIpRange. + * @member {string} matchedIpRange + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @instance + */ + NetworkInfo.prototype.matchedIpRange = ""; + + /** + * NetworkInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo + * @instance + */ + NetworkInfo.prototype.region = ""; + + /** + * Creates a new NetworkInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo instance + * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo instance */ - GoogleServiceInfo.create = function create(properties) { - return new GoogleServiceInfo(properties); + NetworkInfo.create = function create(properties) { + return new NetworkInfo(properties); }; /** - * Encodes the specified GoogleServiceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify|verify} messages. + * Encodes the specified NetworkInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.NetworkInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo} message GoogleServiceInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo} message NetworkInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GoogleServiceInfo.encode = function encode(message, writer) { + NetworkInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.sourceIp != null && Object.hasOwnProperty.call(message, "sourceIp")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.sourceIp); - if (message.googleServiceType != null && Object.hasOwnProperty.call(message, "googleServiceType")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.googleServiceType); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.matchedIpRange != null && Object.hasOwnProperty.call(message, "matchedIpRange")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.matchedIpRange); + if (message.matchedSubnetUri != null && Object.hasOwnProperty.call(message, "matchedSubnetUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.matchedSubnetUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); return writer; }; /** - * Encodes the specified GoogleServiceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify|verify} messages. + * Encodes the specified NetworkInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.NetworkInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo} message GoogleServiceInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.INetworkInfo} message NetworkInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GoogleServiceInfo.encodeDelimited = function encodeDelimited(message, writer) { + NetworkInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GoogleServiceInfo message from the specified reader or buffer. + * Decodes a NetworkInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo + * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GoogleServiceInfo.decode = function decode(reader, length) { + NetworkInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.NetworkInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.sourceIp = reader.string(); + message.displayName = reader.string(); break; } case 2: { - message.googleServiceType = reader.int32(); + message.uri = reader.string(); + break; + } + case 5: { + message.matchedSubnetUri = reader.string(); + break; + } + case 4: { + message.matchedIpRange = reader.string(); + break; + } + case 6: { + message.region = reader.string(); break; } default: @@ -24596,205 +24744,167 @@ }; /** - * Decodes a GoogleServiceInfo message from the specified reader or buffer, length delimited. + * Decodes a NetworkInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo + * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GoogleServiceInfo.decodeDelimited = function decodeDelimited(reader) { + NetworkInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GoogleServiceInfo message. + * Verifies a NetworkInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GoogleServiceInfo.verify = function verify(message) { + NetworkInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) - if (!$util.isString(message.sourceIp)) - return "sourceIp: string expected"; - if (message.googleServiceType != null && message.hasOwnProperty("googleServiceType")) - switch (message.googleServiceType) { - default: - return "googleServiceType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - break; - } + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.matchedSubnetUri != null && message.hasOwnProperty("matchedSubnetUri")) + if (!$util.isString(message.matchedSubnetUri)) + return "matchedSubnetUri: string expected"; + if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) + if (!$util.isString(message.matchedIpRange)) + return "matchedIpRange: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; return null; }; /** - * Creates a GoogleServiceInfo message from a plain object. Also converts values to their respective internal types. + * Creates a NetworkInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo + * @returns {google.cloud.networkmanagement.v1beta1.NetworkInfo} NetworkInfo */ - GoogleServiceInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo) + NetworkInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.NetworkInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo(); - if (object.sourceIp != null) - message.sourceIp = String(object.sourceIp); - switch (object.googleServiceType) { - default: - if (typeof object.googleServiceType === "number") { - message.googleServiceType = object.googleServiceType; - break; - } - break; - case "GOOGLE_SERVICE_TYPE_UNSPECIFIED": - case 0: - message.googleServiceType = 0; - break; - case "IAP": - case 1: - message.googleServiceType = 1; - break; - case "GFE_PROXY_OR_HEALTH_CHECK_PROBER": - case 2: - message.googleServiceType = 2; - break; - case "CLOUD_DNS": - case 3: - message.googleServiceType = 3; - break; - case "GOOGLE_API": - case 4: - message.googleServiceType = 4; - break; - case "GOOGLE_API_PSC": - case 5: - message.googleServiceType = 5; - break; - case "GOOGLE_API_VPC_SC": - case 6: - message.googleServiceType = 6; - break; - } + var message = new $root.google.cloud.networkmanagement.v1beta1.NetworkInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.matchedSubnetUri != null) + message.matchedSubnetUri = String(object.matchedSubnetUri); + if (object.matchedIpRange != null) + message.matchedIpRange = String(object.matchedIpRange); + if (object.region != null) + message.region = String(object.region); return message; }; /** - * Creates a plain object from a GoogleServiceInfo message. Also converts values to other types if specified. + * Creates a plain object from a NetworkInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} message GoogleServiceInfo + * @param {google.cloud.networkmanagement.v1beta1.NetworkInfo} message NetworkInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GoogleServiceInfo.toObject = function toObject(message, options) { + NetworkInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.sourceIp = ""; - object.googleServiceType = options.enums === String ? "GOOGLE_SERVICE_TYPE_UNSPECIFIED" : 0; + object.displayName = ""; + object.uri = ""; + object.matchedIpRange = ""; + object.matchedSubnetUri = ""; + object.region = ""; } - if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) - object.sourceIp = message.sourceIp; - if (message.googleServiceType != null && message.hasOwnProperty("googleServiceType")) - object.googleServiceType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType[message.googleServiceType] === undefined ? message.googleServiceType : $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType[message.googleServiceType] : message.googleServiceType; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.matchedIpRange != null && message.hasOwnProperty("matchedIpRange")) + object.matchedIpRange = message.matchedIpRange; + if (message.matchedSubnetUri != null && message.hasOwnProperty("matchedSubnetUri")) + object.matchedSubnetUri = message.matchedSubnetUri; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; /** - * Converts this GoogleServiceInfo to JSON. + * Converts this NetworkInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @instance * @returns {Object.} JSON object */ - GoogleServiceInfo.prototype.toJSON = function toJSON() { + NetworkInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GoogleServiceInfo + * Gets the default type url for NetworkInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @memberof google.cloud.networkmanagement.v1beta1.NetworkInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GoogleServiceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + NetworkInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.GoogleServiceInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.NetworkInfo"; }; - /** - * GoogleServiceType enum. - * @name google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType - * @enum {number} - * @property {number} GOOGLE_SERVICE_TYPE_UNSPECIFIED=0 GOOGLE_SERVICE_TYPE_UNSPECIFIED value - * @property {number} IAP=1 IAP value - * @property {number} GFE_PROXY_OR_HEALTH_CHECK_PROBER=2 GFE_PROXY_OR_HEALTH_CHECK_PROBER value - * @property {number} CLOUD_DNS=3 CLOUD_DNS value - * @property {number} GOOGLE_API=4 GOOGLE_API value - * @property {number} GOOGLE_API_PSC=5 GOOGLE_API_PSC value - * @property {number} GOOGLE_API_VPC_SC=6 GOOGLE_API_VPC_SC value - */ - GoogleServiceInfo.GoogleServiceType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "GOOGLE_SERVICE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "IAP"] = 1; - values[valuesById[2] = "GFE_PROXY_OR_HEALTH_CHECK_PROBER"] = 2; - values[valuesById[3] = "CLOUD_DNS"] = 3; - values[valuesById[4] = "GOOGLE_API"] = 4; - values[valuesById[5] = "GOOGLE_API_PSC"] = 5; - values[valuesById[6] = "GOOGLE_API_VPC_SC"] = 6; - return values; - })(); - - return GoogleServiceInfo; + return NetworkInfo; })(); - v1beta1.ForwardingRuleInfo = (function() { + v1beta1.FirewallInfo = (function() { /** - * Properties of a ForwardingRuleInfo. + * Properties of a FirewallInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IForwardingRuleInfo - * @property {string|null} [displayName] ForwardingRuleInfo displayName - * @property {string|null} [uri] ForwardingRuleInfo uri - * @property {string|null} [matchedProtocol] ForwardingRuleInfo matchedProtocol - * @property {string|null} [matchedPortRange] ForwardingRuleInfo matchedPortRange - * @property {string|null} [vip] ForwardingRuleInfo vip - * @property {string|null} [target] ForwardingRuleInfo target - * @property {string|null} [networkUri] ForwardingRuleInfo networkUri + * @interface IFirewallInfo + * @property {string|null} [displayName] FirewallInfo displayName + * @property {string|null} [uri] FirewallInfo uri + * @property {string|null} [direction] FirewallInfo direction + * @property {string|null} [action] FirewallInfo action + * @property {number|null} [priority] FirewallInfo priority + * @property {string|null} [networkUri] FirewallInfo networkUri + * @property {Array.|null} [targetTags] FirewallInfo targetTags + * @property {Array.|null} [targetServiceAccounts] FirewallInfo targetServiceAccounts + * @property {string|null} [policy] FirewallInfo policy + * @property {string|null} [policyUri] FirewallInfo policyUri + * @property {google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType|null} [firewallRuleType] FirewallInfo firewallRuleType */ /** - * Constructs a new ForwardingRuleInfo. + * Constructs a new FirewallInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a ForwardingRuleInfo. - * @implements IForwardingRuleInfo + * @classdesc Represents a FirewallInfo. + * @implements IFirewallInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo=} [properties] Properties to set */ - function ForwardingRuleInfo(properties) { + function FirewallInfo(properties) { + this.targetTags = []; + this.targetServiceAccounts = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -24802,130 +24912,172 @@ } /** - * ForwardingRuleInfo displayName. + * FirewallInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.displayName = ""; + FirewallInfo.prototype.displayName = ""; /** - * ForwardingRuleInfo uri. + * FirewallInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.uri = ""; + FirewallInfo.prototype.uri = ""; /** - * ForwardingRuleInfo matchedProtocol. - * @member {string} matchedProtocol - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * FirewallInfo direction. + * @member {string} direction + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.matchedProtocol = ""; + FirewallInfo.prototype.direction = ""; /** - * ForwardingRuleInfo matchedPortRange. - * @member {string} matchedPortRange - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * FirewallInfo action. + * @member {string} action + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.matchedPortRange = ""; + FirewallInfo.prototype.action = ""; /** - * ForwardingRuleInfo vip. - * @member {string} vip - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * FirewallInfo priority. + * @member {number} priority + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.vip = ""; + FirewallInfo.prototype.priority = 0; /** - * ForwardingRuleInfo target. - * @member {string} target - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * FirewallInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.target = ""; + FirewallInfo.prototype.networkUri = ""; /** - * ForwardingRuleInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * FirewallInfo targetTags. + * @member {Array.} targetTags + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance */ - ForwardingRuleInfo.prototype.networkUri = ""; + FirewallInfo.prototype.targetTags = $util.emptyArray; /** - * Creates a new ForwardingRuleInfo instance using the specified properties. + * FirewallInfo targetServiceAccounts. + * @member {Array.} targetServiceAccounts + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @instance + */ + FirewallInfo.prototype.targetServiceAccounts = $util.emptyArray; + + /** + * FirewallInfo policy. + * @member {string} policy + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @instance + */ + FirewallInfo.prototype.policy = ""; + + /** + * FirewallInfo policyUri. + * @member {string} policyUri + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @instance + */ + FirewallInfo.prototype.policyUri = ""; + + /** + * FirewallInfo firewallRuleType. + * @member {google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType} firewallRuleType + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo + * @instance + */ + FirewallInfo.prototype.firewallRuleType = 0; + + /** + * Creates a new FirewallInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo instance */ - ForwardingRuleInfo.create = function create(properties) { - return new ForwardingRuleInfo(properties); + FirewallInfo.create = function create(properties) { + return new FirewallInfo(properties); }; /** - * Encodes the specified ForwardingRuleInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify|verify} messages. + * Encodes the specified FirewallInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.FirewallInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo} message ForwardingRuleInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo} message FirewallInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ForwardingRuleInfo.encode = function encode(message, writer) { + FirewallInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.matchedProtocol != null && Object.hasOwnProperty.call(message, "matchedProtocol")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.matchedProtocol); - if (message.vip != null && Object.hasOwnProperty.call(message, "vip")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.vip); - if (message.target != null && Object.hasOwnProperty.call(message, "target")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.target); - if (message.matchedPortRange != null && Object.hasOwnProperty.call(message, "matchedPortRange")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.matchedPortRange); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkUri); - return writer; - }; + if (message.direction != null && Object.hasOwnProperty.call(message, "direction")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.direction); + if (message.action != null && Object.hasOwnProperty.call(message, "action")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.action); + if (message.priority != null && Object.hasOwnProperty.call(message, "priority")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.priority); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.networkUri); + if (message.targetTags != null && message.targetTags.length) + for (var i = 0; i < message.targetTags.length; ++i) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.targetTags[i]); + if (message.targetServiceAccounts != null && message.targetServiceAccounts.length) + for (var i = 0; i < message.targetServiceAccounts.length; ++i) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.targetServiceAccounts[i]); + if (message.policy != null && Object.hasOwnProperty.call(message, "policy")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.policy); + if (message.firewallRuleType != null && Object.hasOwnProperty.call(message, "firewallRuleType")) + writer.uint32(/* id 10, wireType 0 =*/80).int32(message.firewallRuleType); + if (message.policyUri != null && Object.hasOwnProperty.call(message, "policyUri")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.policyUri); + return writer; + }; /** - * Encodes the specified ForwardingRuleInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify|verify} messages. + * Encodes the specified FirewallInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.FirewallInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo} message ForwardingRuleInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IFirewallInfo} message FirewallInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ForwardingRuleInfo.encodeDelimited = function encodeDelimited(message, writer) { + FirewallInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ForwardingRuleInfo message from the specified reader or buffer. + * Decodes a FirewallInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo + * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ForwardingRuleInfo.decode = function decode(reader, length) { + FirewallInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.FirewallInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -24938,25 +25090,45 @@ break; } case 3: { - message.matchedProtocol = reader.string(); - break; - } - case 6: { - message.matchedPortRange = reader.string(); + message.direction = reader.string(); break; } case 4: { - message.vip = reader.string(); + message.action = reader.string(); break; } case 5: { - message.target = reader.string(); + message.priority = reader.int32(); break; } - case 7: { + case 6: { message.networkUri = reader.string(); break; } + case 7: { + if (!(message.targetTags && message.targetTags.length)) + message.targetTags = []; + message.targetTags.push(reader.string()); + break; + } + case 8: { + if (!(message.targetServiceAccounts && message.targetServiceAccounts.length)) + message.targetServiceAccounts = []; + message.targetServiceAccounts.push(reader.string()); + break; + } + case 9: { + message.policy = reader.string(); + break; + } + case 11: { + message.policyUri = reader.string(); + break; + } + case 10: { + message.firewallRuleType = reader.int32(); + break; + } default: reader.skipType(tag & 7); break; @@ -24966,30 +25138,30 @@ }; /** - * Decodes a ForwardingRuleInfo message from the specified reader or buffer, length delimited. + * Decodes a FirewallInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo + * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ForwardingRuleInfo.decodeDelimited = function decodeDelimited(reader) { + FirewallInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ForwardingRuleInfo message. + * Verifies a FirewallInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ForwardingRuleInfo.verify = function verify(message) { + FirewallInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -24998,144 +25170,301 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; - if (message.matchedProtocol != null && message.hasOwnProperty("matchedProtocol")) - if (!$util.isString(message.matchedProtocol)) - return "matchedProtocol: string expected"; - if (message.matchedPortRange != null && message.hasOwnProperty("matchedPortRange")) - if (!$util.isString(message.matchedPortRange)) - return "matchedPortRange: string expected"; - if (message.vip != null && message.hasOwnProperty("vip")) - if (!$util.isString(message.vip)) - return "vip: string expected"; - if (message.target != null && message.hasOwnProperty("target")) - if (!$util.isString(message.target)) - return "target: string expected"; + if (message.direction != null && message.hasOwnProperty("direction")) + if (!$util.isString(message.direction)) + return "direction: string expected"; + if (message.action != null && message.hasOwnProperty("action")) + if (!$util.isString(message.action)) + return "action: string expected"; + if (message.priority != null && message.hasOwnProperty("priority")) + if (!$util.isInteger(message.priority)) + return "priority: integer expected"; if (message.networkUri != null && message.hasOwnProperty("networkUri")) if (!$util.isString(message.networkUri)) return "networkUri: string expected"; + if (message.targetTags != null && message.hasOwnProperty("targetTags")) { + if (!Array.isArray(message.targetTags)) + return "targetTags: array expected"; + for (var i = 0; i < message.targetTags.length; ++i) + if (!$util.isString(message.targetTags[i])) + return "targetTags: string[] expected"; + } + if (message.targetServiceAccounts != null && message.hasOwnProperty("targetServiceAccounts")) { + if (!Array.isArray(message.targetServiceAccounts)) + return "targetServiceAccounts: array expected"; + for (var i = 0; i < message.targetServiceAccounts.length; ++i) + if (!$util.isString(message.targetServiceAccounts[i])) + return "targetServiceAccounts: string[] expected"; + } + if (message.policy != null && message.hasOwnProperty("policy")) + if (!$util.isString(message.policy)) + return "policy: string expected"; + if (message.policyUri != null && message.hasOwnProperty("policyUri")) + if (!$util.isString(message.policyUri)) + return "policyUri: string expected"; + if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) + switch (message.firewallRuleType) { + default: + return "firewallRuleType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 100: + case 101: + break; + } return null; }; /** - * Creates a ForwardingRuleInfo message from a plain object. Also converts values to their respective internal types. + * Creates a FirewallInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo + * @returns {google.cloud.networkmanagement.v1beta1.FirewallInfo} FirewallInfo */ - ForwardingRuleInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo) + FirewallInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.FirewallInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo(); + var message = new $root.google.cloud.networkmanagement.v1beta1.FirewallInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); - if (object.matchedProtocol != null) - message.matchedProtocol = String(object.matchedProtocol); - if (object.matchedPortRange != null) - message.matchedPortRange = String(object.matchedPortRange); - if (object.vip != null) - message.vip = String(object.vip); - if (object.target != null) - message.target = String(object.target); + if (object.direction != null) + message.direction = String(object.direction); + if (object.action != null) + message.action = String(object.action); + if (object.priority != null) + message.priority = object.priority | 0; if (object.networkUri != null) message.networkUri = String(object.networkUri); + if (object.targetTags) { + if (!Array.isArray(object.targetTags)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.FirewallInfo.targetTags: array expected"); + message.targetTags = []; + for (var i = 0; i < object.targetTags.length; ++i) + message.targetTags[i] = String(object.targetTags[i]); + } + if (object.targetServiceAccounts) { + if (!Array.isArray(object.targetServiceAccounts)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.FirewallInfo.targetServiceAccounts: array expected"); + message.targetServiceAccounts = []; + for (var i = 0; i < object.targetServiceAccounts.length; ++i) + message.targetServiceAccounts[i] = String(object.targetServiceAccounts[i]); + } + if (object.policy != null) + message.policy = String(object.policy); + if (object.policyUri != null) + message.policyUri = String(object.policyUri); + switch (object.firewallRuleType) { + default: + if (typeof object.firewallRuleType === "number") { + message.firewallRuleType = object.firewallRuleType; + break; + } + break; + case "FIREWALL_RULE_TYPE_UNSPECIFIED": + case 0: + message.firewallRuleType = 0; + break; + case "HIERARCHICAL_FIREWALL_POLICY_RULE": + case 1: + message.firewallRuleType = 1; + break; + case "VPC_FIREWALL_RULE": + case 2: + message.firewallRuleType = 2; + break; + case "IMPLIED_VPC_FIREWALL_RULE": + case 3: + message.firewallRuleType = 3; + break; + case "SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE": + case 4: + message.firewallRuleType = 4; + break; + case "NETWORK_FIREWALL_POLICY_RULE": + case 5: + message.firewallRuleType = 5; + break; + case "NETWORK_REGIONAL_FIREWALL_POLICY_RULE": + case 6: + message.firewallRuleType = 6; + break; + case "UNSUPPORTED_FIREWALL_POLICY_RULE": + case 100: + message.firewallRuleType = 100; + break; + case "TRACKING_STATE": + case 101: + message.firewallRuleType = 101; + break; + } return message; }; /** - * Creates a plain object from a ForwardingRuleInfo message. Also converts values to other types if specified. + * Creates a plain object from a FirewallInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} message ForwardingRuleInfo + * @param {google.cloud.networkmanagement.v1beta1.FirewallInfo} message FirewallInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ForwardingRuleInfo.toObject = function toObject(message, options) { + FirewallInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.targetTags = []; + object.targetServiceAccounts = []; + } if (options.defaults) { object.displayName = ""; object.uri = ""; - object.matchedProtocol = ""; - object.vip = ""; - object.target = ""; - object.matchedPortRange = ""; + object.direction = ""; + object.action = ""; + object.priority = 0; object.networkUri = ""; + object.policy = ""; + object.firewallRuleType = options.enums === String ? "FIREWALL_RULE_TYPE_UNSPECIFIED" : 0; + object.policyUri = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.matchedProtocol != null && message.hasOwnProperty("matchedProtocol")) - object.matchedProtocol = message.matchedProtocol; - if (message.vip != null && message.hasOwnProperty("vip")) - object.vip = message.vip; - if (message.target != null && message.hasOwnProperty("target")) - object.target = message.target; - if (message.matchedPortRange != null && message.hasOwnProperty("matchedPortRange")) - object.matchedPortRange = message.matchedPortRange; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (message.direction != null && message.hasOwnProperty("direction")) + object.direction = message.direction; + if (message.action != null && message.hasOwnProperty("action")) + object.action = message.action; + if (message.priority != null && message.hasOwnProperty("priority")) + object.priority = message.priority; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) object.networkUri = message.networkUri; + if (message.targetTags && message.targetTags.length) { + object.targetTags = []; + for (var j = 0; j < message.targetTags.length; ++j) + object.targetTags[j] = message.targetTags[j]; + } + if (message.targetServiceAccounts && message.targetServiceAccounts.length) { + object.targetServiceAccounts = []; + for (var j = 0; j < message.targetServiceAccounts.length; ++j) + object.targetServiceAccounts[j] = message.targetServiceAccounts[j]; + } + if (message.policy != null && message.hasOwnProperty("policy")) + object.policy = message.policy; + if (message.firewallRuleType != null && message.hasOwnProperty("firewallRuleType")) + object.firewallRuleType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType[message.firewallRuleType] === undefined ? message.firewallRuleType : $root.google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType[message.firewallRuleType] : message.firewallRuleType; + if (message.policyUri != null && message.hasOwnProperty("policyUri")) + object.policyUri = message.policyUri; return object; }; /** - * Converts this ForwardingRuleInfo to JSON. + * Converts this FirewallInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @instance * @returns {Object.} JSON object */ - ForwardingRuleInfo.prototype.toJSON = function toJSON() { + FirewallInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ForwardingRuleInfo + * Gets the default type url for FirewallInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @memberof google.cloud.networkmanagement.v1beta1.FirewallInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ForwardingRuleInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FirewallInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.FirewallInfo"; }; - return ForwardingRuleInfo; + /** + * FirewallRuleType enum. + * @name google.cloud.networkmanagement.v1beta1.FirewallInfo.FirewallRuleType + * @enum {number} + * @property {number} FIREWALL_RULE_TYPE_UNSPECIFIED=0 FIREWALL_RULE_TYPE_UNSPECIFIED value + * @property {number} HIERARCHICAL_FIREWALL_POLICY_RULE=1 HIERARCHICAL_FIREWALL_POLICY_RULE value + * @property {number} VPC_FIREWALL_RULE=2 VPC_FIREWALL_RULE value + * @property {number} IMPLIED_VPC_FIREWALL_RULE=3 IMPLIED_VPC_FIREWALL_RULE value + * @property {number} SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE=4 SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE value + * @property {number} NETWORK_FIREWALL_POLICY_RULE=5 NETWORK_FIREWALL_POLICY_RULE value + * @property {number} NETWORK_REGIONAL_FIREWALL_POLICY_RULE=6 NETWORK_REGIONAL_FIREWALL_POLICY_RULE value + * @property {number} UNSUPPORTED_FIREWALL_POLICY_RULE=100 UNSUPPORTED_FIREWALL_POLICY_RULE value + * @property {number} TRACKING_STATE=101 TRACKING_STATE value + */ + FirewallInfo.FirewallRuleType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "FIREWALL_RULE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "HIERARCHICAL_FIREWALL_POLICY_RULE"] = 1; + values[valuesById[2] = "VPC_FIREWALL_RULE"] = 2; + values[valuesById[3] = "IMPLIED_VPC_FIREWALL_RULE"] = 3; + values[valuesById[4] = "SERVERLESS_VPC_ACCESS_MANAGED_FIREWALL_RULE"] = 4; + values[valuesById[5] = "NETWORK_FIREWALL_POLICY_RULE"] = 5; + values[valuesById[6] = "NETWORK_REGIONAL_FIREWALL_POLICY_RULE"] = 6; + values[valuesById[100] = "UNSUPPORTED_FIREWALL_POLICY_RULE"] = 100; + values[valuesById[101] = "TRACKING_STATE"] = 101; + return values; + })(); + + return FirewallInfo; })(); - v1beta1.LoadBalancerInfo = (function() { + v1beta1.RouteInfo = (function() { /** - * Properties of a LoadBalancerInfo. + * Properties of a RouteInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ILoadBalancerInfo - * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType|null} [loadBalancerType] LoadBalancerInfo loadBalancerType - * @property {string|null} [healthCheckUri] LoadBalancerInfo healthCheckUri - * @property {Array.|null} [backends] LoadBalancerInfo backends - * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType|null} [backendType] LoadBalancerInfo backendType - * @property {string|null} [backendUri] LoadBalancerInfo backendUri + * @interface IRouteInfo + * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType|null} [routeType] RouteInfo routeType + * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType|null} [nextHopType] RouteInfo nextHopType + * @property {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope|null} [routeScope] RouteInfo routeScope + * @property {string|null} [displayName] RouteInfo displayName + * @property {string|null} [uri] RouteInfo uri + * @property {string|null} [region] RouteInfo region + * @property {string|null} [destIpRange] RouteInfo destIpRange + * @property {string|null} [nextHop] RouteInfo nextHop + * @property {string|null} [networkUri] RouteInfo networkUri + * @property {number|null} [priority] RouteInfo priority + * @property {Array.|null} [instanceTags] RouteInfo instanceTags + * @property {string|null} [srcIpRange] RouteInfo srcIpRange + * @property {Array.|null} [destPortRanges] RouteInfo destPortRanges + * @property {Array.|null} [srcPortRanges] RouteInfo srcPortRanges + * @property {Array.|null} [protocols] RouteInfo protocols + * @property {string|null} [nccHubUri] RouteInfo nccHubUri + * @property {string|null} [nccSpokeUri] RouteInfo nccSpokeUri + * @property {string|null} [advertisedRouteSourceRouterUri] RouteInfo advertisedRouteSourceRouterUri + * @property {string|null} [advertisedRouteNextHopUri] RouteInfo advertisedRouteNextHopUri */ /** - * Constructs a new LoadBalancerInfo. + * Constructs a new RouteInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a LoadBalancerInfo. - * @implements ILoadBalancerInfo + * @classdesc Represents a RouteInfo. + * @implements IRouteInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo=} [properties] Properties to set */ - function LoadBalancerInfo(properties) { - this.backends = []; + function RouteInfo(properties) { + this.instanceTags = []; + this.destPortRanges = []; + this.srcPortRanges = []; + this.protocols = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -25143,542 +25472,316 @@ } /** - * LoadBalancerInfo loadBalancerType. - * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType} loadBalancerType - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo routeType. + * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType} routeType + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerInfo.prototype.loadBalancerType = 0; + RouteInfo.prototype.routeType = 0; /** - * LoadBalancerInfo healthCheckUri. - * @member {string} healthCheckUri - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo nextHopType. + * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType} nextHopType + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerInfo.prototype.healthCheckUri = ""; + RouteInfo.prototype.nextHopType = 0; /** - * LoadBalancerInfo backends. - * @member {Array.} backends - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo routeScope. + * @member {google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope} routeScope + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerInfo.prototype.backends = $util.emptyArray; + RouteInfo.prototype.routeScope = 0; /** - * LoadBalancerInfo backendType. - * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType} backendType - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerInfo.prototype.backendType = 0; + RouteInfo.prototype.displayName = ""; /** - * LoadBalancerInfo backendUri. - * @member {string} backendUri - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerInfo.prototype.backendUri = ""; + RouteInfo.prototype.uri = ""; /** - * Creates a new LoadBalancerInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo instance + * RouteInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.create = function create(properties) { - return new LoadBalancerInfo(properties); - }; + RouteInfo.prototype.region = ""; /** - * Encodes the specified LoadBalancerInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo} message LoadBalancerInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * RouteInfo destIpRange. + * @member {string} destIpRange + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.loadBalancerType != null && Object.hasOwnProperty.call(message, "loadBalancerType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.loadBalancerType); - if (message.healthCheckUri != null && Object.hasOwnProperty.call(message, "healthCheckUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.healthCheckUri); - if (message.backends != null && message.backends.length) - for (var i = 0; i < message.backends.length; ++i) - $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.encode(message.backends[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.backendType != null && Object.hasOwnProperty.call(message, "backendType")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.backendType); - if (message.backendUri != null && Object.hasOwnProperty.call(message, "backendUri")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.backendUri); - return writer; - }; + RouteInfo.prototype.destIpRange = ""; /** - * Encodes the specified LoadBalancerInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo} message LoadBalancerInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * RouteInfo nextHop. + * @member {string} nextHop + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + RouteInfo.prototype.nextHop = ""; /** - * Decodes a LoadBalancerInfo message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * RouteInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.loadBalancerType = reader.int32(); - break; - } - case 2: { - message.healthCheckUri = reader.string(); - break; - } - case 3: { - if (!(message.backends && message.backends.length)) - message.backends = []; - message.backends.push($root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.decode(reader, reader.uint32())); - break; - } - case 4: { - message.backendType = reader.int32(); - break; - } - case 5: { - message.backendUri = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + RouteInfo.prototype.networkUri = ""; /** - * Decodes a LoadBalancerInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * RouteInfo priority. + * @member {number} priority + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + RouteInfo.prototype.priority = 0; /** - * Verifies a LoadBalancerInfo message. - * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * RouteInfo instanceTags. + * @member {Array.} instanceTags + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) - switch (message.loadBalancerType) { - default: - return "loadBalancerType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - break; - } - if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) - if (!$util.isString(message.healthCheckUri)) - return "healthCheckUri: string expected"; - if (message.backends != null && message.hasOwnProperty("backends")) { - if (!Array.isArray(message.backends)) - return "backends: array expected"; - for (var i = 0; i < message.backends.length; ++i) { - var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify(message.backends[i]); - if (error) - return "backends." + error; - } - } - if (message.backendType != null && message.hasOwnProperty("backendType")) - switch (message.backendType) { - default: - return "backendType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } - if (message.backendUri != null && message.hasOwnProperty("backendUri")) - if (!$util.isString(message.backendUri)) - return "backendUri: string expected"; - return null; - }; + RouteInfo.prototype.instanceTags = $util.emptyArray; /** - * Creates a LoadBalancerInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo + * RouteInfo srcIpRange. + * @member {string} srcIpRange + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo) - return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo(); - switch (object.loadBalancerType) { - default: - if (typeof object.loadBalancerType === "number") { - message.loadBalancerType = object.loadBalancerType; - break; - } - break; - case "LOAD_BALANCER_TYPE_UNSPECIFIED": - case 0: - message.loadBalancerType = 0; - break; - case "INTERNAL_TCP_UDP": - case 1: - message.loadBalancerType = 1; - break; - case "NETWORK_TCP_UDP": - case 2: - message.loadBalancerType = 2; - break; - case "HTTP_PROXY": - case 3: - message.loadBalancerType = 3; - break; - case "TCP_PROXY": - case 4: - message.loadBalancerType = 4; - break; - case "SSL_PROXY": - case 5: - message.loadBalancerType = 5; - break; - } - if (object.healthCheckUri != null) - message.healthCheckUri = String(object.healthCheckUri); - if (object.backends) { - if (!Array.isArray(object.backends)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.backends: array expected"); - message.backends = []; - for (var i = 0; i < object.backends.length; ++i) { - if (typeof object.backends[i] !== "object") - throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.backends: object expected"); - message.backends[i] = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.fromObject(object.backends[i]); - } - } - switch (object.backendType) { - default: - if (typeof object.backendType === "number") { - message.backendType = object.backendType; - break; - } - break; - case "BACKEND_TYPE_UNSPECIFIED": - case 0: - message.backendType = 0; - break; - case "BACKEND_SERVICE": - case 1: - message.backendType = 1; - break; - case "TARGET_POOL": - case 2: - message.backendType = 2; - break; - case "TARGET_INSTANCE": - case 3: - message.backendType = 3; - break; - } - if (object.backendUri != null) - message.backendUri = String(object.backendUri); - return message; - }; + RouteInfo.prototype.srcIpRange = ""; /** - * Creates a plain object from a LoadBalancerInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} message LoadBalancerInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * RouteInfo destPortRanges. + * @member {Array.} destPortRanges + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.backends = []; - if (options.defaults) { - object.loadBalancerType = options.enums === String ? "LOAD_BALANCER_TYPE_UNSPECIFIED" : 0; - object.healthCheckUri = ""; - object.backendType = options.enums === String ? "BACKEND_TYPE_UNSPECIFIED" : 0; - object.backendUri = ""; - } - if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) - object.loadBalancerType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType[message.loadBalancerType] === undefined ? message.loadBalancerType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType[message.loadBalancerType] : message.loadBalancerType; - if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) - object.healthCheckUri = message.healthCheckUri; - if (message.backends && message.backends.length) { - object.backends = []; - for (var j = 0; j < message.backends.length; ++j) - object.backends[j] = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.toObject(message.backends[j], options); - } - if (message.backendType != null && message.hasOwnProperty("backendType")) - object.backendType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType[message.backendType] === undefined ? message.backendType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType[message.backendType] : message.backendType; - if (message.backendUri != null && message.hasOwnProperty("backendUri")) - object.backendUri = message.backendUri; - return object; - }; + RouteInfo.prototype.destPortRanges = $util.emptyArray; /** - * Converts this LoadBalancerInfo to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * RouteInfo srcPortRanges. + * @member {Array.} srcPortRanges + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance - * @returns {Object.} JSON object */ - LoadBalancerInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + RouteInfo.prototype.srcPortRanges = $util.emptyArray; /** - * Gets the default type url for LoadBalancerInfo - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * RouteInfo protocols. + * @member {Array.} protocols + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LoadBalancerInfo"; - }; + RouteInfo.prototype.protocols = $util.emptyArray; /** - * LoadBalancerType enum. - * @name google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType - * @enum {number} - * @property {number} LOAD_BALANCER_TYPE_UNSPECIFIED=0 LOAD_BALANCER_TYPE_UNSPECIFIED value - * @property {number} INTERNAL_TCP_UDP=1 INTERNAL_TCP_UDP value - * @property {number} NETWORK_TCP_UDP=2 NETWORK_TCP_UDP value - * @property {number} HTTP_PROXY=3 HTTP_PROXY value - * @property {number} TCP_PROXY=4 TCP_PROXY value - * @property {number} SSL_PROXY=5 SSL_PROXY value + * RouteInfo nccHubUri. + * @member {string|null|undefined} nccHubUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - LoadBalancerInfo.LoadBalancerType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "LOAD_BALANCER_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "INTERNAL_TCP_UDP"] = 1; - values[valuesById[2] = "NETWORK_TCP_UDP"] = 2; - values[valuesById[3] = "HTTP_PROXY"] = 3; - values[valuesById[4] = "TCP_PROXY"] = 4; - values[valuesById[5] = "SSL_PROXY"] = 5; - return values; - })(); + RouteInfo.prototype.nccHubUri = null; /** - * BackendType enum. - * @name google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType - * @enum {number} - * @property {number} BACKEND_TYPE_UNSPECIFIED=0 BACKEND_TYPE_UNSPECIFIED value - * @property {number} BACKEND_SERVICE=1 BACKEND_SERVICE value - * @property {number} TARGET_POOL=2 TARGET_POOL value - * @property {number} TARGET_INSTANCE=3 TARGET_INSTANCE value - */ - LoadBalancerInfo.BackendType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "BACKEND_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "BACKEND_SERVICE"] = 1; - values[valuesById[2] = "TARGET_POOL"] = 2; - values[valuesById[3] = "TARGET_INSTANCE"] = 3; - return values; - })(); - - return LoadBalancerInfo; - })(); - - v1beta1.LoadBalancerBackend = (function() { - - /** - * Properties of a LoadBalancerBackend. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ILoadBalancerBackend - * @property {string|null} [displayName] LoadBalancerBackend displayName - * @property {string|null} [uri] LoadBalancerBackend uri - * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState|null} [healthCheckFirewallState] LoadBalancerBackend healthCheckFirewallState - * @property {Array.|null} [healthCheckAllowingFirewallRules] LoadBalancerBackend healthCheckAllowingFirewallRules - * @property {Array.|null} [healthCheckBlockingFirewallRules] LoadBalancerBackend healthCheckBlockingFirewallRules + * RouteInfo nccSpokeUri. + * @member {string|null|undefined} nccSpokeUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ + RouteInfo.prototype.nccSpokeUri = null; /** - * Constructs a new LoadBalancerBackend. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a LoadBalancerBackend. - * @implements ILoadBalancerBackend - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend=} [properties] Properties to set + * RouteInfo advertisedRouteSourceRouterUri. + * @member {string|null|undefined} advertisedRouteSourceRouterUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @instance */ - function LoadBalancerBackend(properties) { - this.healthCheckAllowingFirewallRules = []; - this.healthCheckBlockingFirewallRules = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + RouteInfo.prototype.advertisedRouteSourceRouterUri = null; /** - * LoadBalancerBackend displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * RouteInfo advertisedRouteNextHopUri. + * @member {string|null|undefined} advertisedRouteNextHopUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerBackend.prototype.displayName = ""; + RouteInfo.prototype.advertisedRouteNextHopUri = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * LoadBalancerBackend uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * RouteInfo _nccHubUri. + * @member {"nccHubUri"|undefined} _nccHubUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerBackend.prototype.uri = ""; + Object.defineProperty(RouteInfo.prototype, "_nccHubUri", { + get: $util.oneOfGetter($oneOfFields = ["nccHubUri"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * LoadBalancerBackend healthCheckFirewallState. - * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState} healthCheckFirewallState - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * RouteInfo _nccSpokeUri. + * @member {"nccSpokeUri"|undefined} _nccSpokeUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerBackend.prototype.healthCheckFirewallState = 0; + Object.defineProperty(RouteInfo.prototype, "_nccSpokeUri", { + get: $util.oneOfGetter($oneOfFields = ["nccSpokeUri"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * LoadBalancerBackend healthCheckAllowingFirewallRules. - * @member {Array.} healthCheckAllowingFirewallRules - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * RouteInfo _advertisedRouteSourceRouterUri. + * @member {"advertisedRouteSourceRouterUri"|undefined} _advertisedRouteSourceRouterUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerBackend.prototype.healthCheckAllowingFirewallRules = $util.emptyArray; + Object.defineProperty(RouteInfo.prototype, "_advertisedRouteSourceRouterUri", { + get: $util.oneOfGetter($oneOfFields = ["advertisedRouteSourceRouterUri"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * LoadBalancerBackend healthCheckBlockingFirewallRules. - * @member {Array.} healthCheckBlockingFirewallRules - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * RouteInfo _advertisedRouteNextHopUri. + * @member {"advertisedRouteNextHopUri"|undefined} _advertisedRouteNextHopUri + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance */ - LoadBalancerBackend.prototype.healthCheckBlockingFirewallRules = $util.emptyArray; + Object.defineProperty(RouteInfo.prototype, "_advertisedRouteNextHopUri", { + get: $util.oneOfGetter($oneOfFields = ["advertisedRouteNextHopUri"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new LoadBalancerBackend instance using the specified properties. + * Creates a new RouteInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend instance + * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo instance */ - LoadBalancerBackend.create = function create(properties) { - return new LoadBalancerBackend(properties); + RouteInfo.create = function create(properties) { + return new RouteInfo(properties); }; /** - * Encodes the specified LoadBalancerBackend message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify|verify} messages. + * Encodes the specified RouteInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RouteInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend} message LoadBalancerBackend message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo} message RouteInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - LoadBalancerBackend.encode = function encode(message, writer) { + RouteInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.healthCheckFirewallState != null && Object.hasOwnProperty.call(message, "healthCheckFirewallState")) - writer.uint32(/* id 3, wireType 0 =*/24).int32(message.healthCheckFirewallState); - if (message.healthCheckAllowingFirewallRules != null && message.healthCheckAllowingFirewallRules.length) - for (var i = 0; i < message.healthCheckAllowingFirewallRules.length; ++i) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.healthCheckAllowingFirewallRules[i]); - if (message.healthCheckBlockingFirewallRules != null && message.healthCheckBlockingFirewallRules.length) - for (var i = 0; i < message.healthCheckBlockingFirewallRules.length; ++i) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.healthCheckBlockingFirewallRules[i]); + if (message.destIpRange != null && Object.hasOwnProperty.call(message, "destIpRange")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.destIpRange); + if (message.nextHop != null && Object.hasOwnProperty.call(message, "nextHop")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.nextHop); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.networkUri); + if (message.priority != null && Object.hasOwnProperty.call(message, "priority")) + writer.uint32(/* id 6, wireType 0 =*/48).int32(message.priority); + if (message.instanceTags != null && message.instanceTags.length) + for (var i = 0; i < message.instanceTags.length; ++i) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.instanceTags[i]); + if (message.routeType != null && Object.hasOwnProperty.call(message, "routeType")) + writer.uint32(/* id 8, wireType 0 =*/64).int32(message.routeType); + if (message.nextHopType != null && Object.hasOwnProperty.call(message, "nextHopType")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.nextHopType); + if (message.srcIpRange != null && Object.hasOwnProperty.call(message, "srcIpRange")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.srcIpRange); + if (message.destPortRanges != null && message.destPortRanges.length) + for (var i = 0; i < message.destPortRanges.length; ++i) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.destPortRanges[i]); + if (message.srcPortRanges != null && message.srcPortRanges.length) + for (var i = 0; i < message.srcPortRanges.length; ++i) + writer.uint32(/* id 12, wireType 2 =*/98).string(message.srcPortRanges[i]); + if (message.protocols != null && message.protocols.length) + for (var i = 0; i < message.protocols.length; ++i) + writer.uint32(/* id 13, wireType 2 =*/106).string(message.protocols[i]); + if (message.routeScope != null && Object.hasOwnProperty.call(message, "routeScope")) + writer.uint32(/* id 14, wireType 0 =*/112).int32(message.routeScope); + if (message.nccHubUri != null && Object.hasOwnProperty.call(message, "nccHubUri")) + writer.uint32(/* id 15, wireType 2 =*/122).string(message.nccHubUri); + if (message.nccSpokeUri != null && Object.hasOwnProperty.call(message, "nccSpokeUri")) + writer.uint32(/* id 16, wireType 2 =*/130).string(message.nccSpokeUri); + if (message.advertisedRouteSourceRouterUri != null && Object.hasOwnProperty.call(message, "advertisedRouteSourceRouterUri")) + writer.uint32(/* id 17, wireType 2 =*/138).string(message.advertisedRouteSourceRouterUri); + if (message.advertisedRouteNextHopUri != null && Object.hasOwnProperty.call(message, "advertisedRouteNextHopUri")) + writer.uint32(/* id 18, wireType 2 =*/146).string(message.advertisedRouteNextHopUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 19, wireType 2 =*/154).string(message.region); return writer; }; /** - * Encodes the specified LoadBalancerBackend message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify|verify} messages. + * Encodes the specified RouteInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RouteInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend} message LoadBalancerBackend message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRouteInfo} message RouteInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - LoadBalancerBackend.encodeDelimited = function encodeDelimited(message, writer) { + RouteInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a LoadBalancerBackend message from the specified reader or buffer. + * Decodes a RouteInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend + * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - LoadBalancerBackend.decode = function decode(reader, length) { + RouteInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.RouteInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 8: { + message.routeType = reader.int32(); + break; + } + case 9: { + message.nextHopType = reader.int32(); + break; + } + case 14: { + message.routeScope = reader.int32(); + break; + } case 1: { message.displayName = reader.string(); break; @@ -25687,20 +25790,68 @@ message.uri = reader.string(); break; } + case 19: { + message.region = reader.string(); + break; + } case 3: { - message.healthCheckFirewallState = reader.int32(); + message.destIpRange = reader.string(); break; } case 4: { - if (!(message.healthCheckAllowingFirewallRules && message.healthCheckAllowingFirewallRules.length)) - message.healthCheckAllowingFirewallRules = []; - message.healthCheckAllowingFirewallRules.push(reader.string()); + message.nextHop = reader.string(); break; } case 5: { - if (!(message.healthCheckBlockingFirewallRules && message.healthCheckBlockingFirewallRules.length)) - message.healthCheckBlockingFirewallRules = []; - message.healthCheckBlockingFirewallRules.push(reader.string()); + message.networkUri = reader.string(); + break; + } + case 6: { + message.priority = reader.int32(); + break; + } + case 7: { + if (!(message.instanceTags && message.instanceTags.length)) + message.instanceTags = []; + message.instanceTags.push(reader.string()); + break; + } + case 10: { + message.srcIpRange = reader.string(); + break; + } + case 11: { + if (!(message.destPortRanges && message.destPortRanges.length)) + message.destPortRanges = []; + message.destPortRanges.push(reader.string()); + break; + } + case 12: { + if (!(message.srcPortRanges && message.srcPortRanges.length)) + message.srcPortRanges = []; + message.srcPortRanges.push(reader.string()); + break; + } + case 13: { + if (!(message.protocols && message.protocols.length)) + message.protocols = []; + message.protocols.push(reader.string()); + break; + } + case 15: { + message.nccHubUri = reader.string(); + break; + } + case 16: { + message.nccSpokeUri = reader.string(); + break; + } + case 17: { + message.advertisedRouteSourceRouterUri = reader.string(); + break; + } + case 18: { + message.advertisedRouteNextHopUri = reader.string(); break; } default: @@ -25712,372 +25863,657 @@ }; /** - * Decodes a LoadBalancerBackend message from the specified reader or buffer, length delimited. + * Decodes a RouteInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend + * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - LoadBalancerBackend.decodeDelimited = function decodeDelimited(reader) { + RouteInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a LoadBalancerBackend message. + * Verifies a RouteInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - LoadBalancerBackend.verify = function verify(message) { + RouteInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - if (message.healthCheckFirewallState != null && message.hasOwnProperty("healthCheckFirewallState")) - switch (message.healthCheckFirewallState) { + var properties = {}; + if (message.routeType != null && message.hasOwnProperty("routeType")) + switch (message.routeType) { default: - return "healthCheckFirewallState: enum value expected"; + return "routeType: enum value expected"; case 0: case 1: case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 101: break; } - if (message.healthCheckAllowingFirewallRules != null && message.hasOwnProperty("healthCheckAllowingFirewallRules")) { - if (!Array.isArray(message.healthCheckAllowingFirewallRules)) - return "healthCheckAllowingFirewallRules: array expected"; - for (var i = 0; i < message.healthCheckAllowingFirewallRules.length; ++i) - if (!$util.isString(message.healthCheckAllowingFirewallRules[i])) - return "healthCheckAllowingFirewallRules: string[] expected"; + if (message.nextHopType != null && message.hasOwnProperty("nextHopType")) + switch (message.nextHopType) { + default: + return "nextHopType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + case 9: + case 10: + case 11: + case 12: + break; + } + if (message.routeScope != null && message.hasOwnProperty("routeScope")) + switch (message.routeScope) { + default: + return "routeScope: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; + if (message.destIpRange != null && message.hasOwnProperty("destIpRange")) + if (!$util.isString(message.destIpRange)) + return "destIpRange: string expected"; + if (message.nextHop != null && message.hasOwnProperty("nextHop")) + if (!$util.isString(message.nextHop)) + return "nextHop: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.priority != null && message.hasOwnProperty("priority")) + if (!$util.isInteger(message.priority)) + return "priority: integer expected"; + if (message.instanceTags != null && message.hasOwnProperty("instanceTags")) { + if (!Array.isArray(message.instanceTags)) + return "instanceTags: array expected"; + for (var i = 0; i < message.instanceTags.length; ++i) + if (!$util.isString(message.instanceTags[i])) + return "instanceTags: string[] expected"; } - if (message.healthCheckBlockingFirewallRules != null && message.hasOwnProperty("healthCheckBlockingFirewallRules")) { - if (!Array.isArray(message.healthCheckBlockingFirewallRules)) - return "healthCheckBlockingFirewallRules: array expected"; - for (var i = 0; i < message.healthCheckBlockingFirewallRules.length; ++i) - if (!$util.isString(message.healthCheckBlockingFirewallRules[i])) - return "healthCheckBlockingFirewallRules: string[] expected"; + if (message.srcIpRange != null && message.hasOwnProperty("srcIpRange")) + if (!$util.isString(message.srcIpRange)) + return "srcIpRange: string expected"; + if (message.destPortRanges != null && message.hasOwnProperty("destPortRanges")) { + if (!Array.isArray(message.destPortRanges)) + return "destPortRanges: array expected"; + for (var i = 0; i < message.destPortRanges.length; ++i) + if (!$util.isString(message.destPortRanges[i])) + return "destPortRanges: string[] expected"; + } + if (message.srcPortRanges != null && message.hasOwnProperty("srcPortRanges")) { + if (!Array.isArray(message.srcPortRanges)) + return "srcPortRanges: array expected"; + for (var i = 0; i < message.srcPortRanges.length; ++i) + if (!$util.isString(message.srcPortRanges[i])) + return "srcPortRanges: string[] expected"; + } + if (message.protocols != null && message.hasOwnProperty("protocols")) { + if (!Array.isArray(message.protocols)) + return "protocols: array expected"; + for (var i = 0; i < message.protocols.length; ++i) + if (!$util.isString(message.protocols[i])) + return "protocols: string[] expected"; + } + if (message.nccHubUri != null && message.hasOwnProperty("nccHubUri")) { + properties._nccHubUri = 1; + if (!$util.isString(message.nccHubUri)) + return "nccHubUri: string expected"; + } + if (message.nccSpokeUri != null && message.hasOwnProperty("nccSpokeUri")) { + properties._nccSpokeUri = 1; + if (!$util.isString(message.nccSpokeUri)) + return "nccSpokeUri: string expected"; + } + if (message.advertisedRouteSourceRouterUri != null && message.hasOwnProperty("advertisedRouteSourceRouterUri")) { + properties._advertisedRouteSourceRouterUri = 1; + if (!$util.isString(message.advertisedRouteSourceRouterUri)) + return "advertisedRouteSourceRouterUri: string expected"; + } + if (message.advertisedRouteNextHopUri != null && message.hasOwnProperty("advertisedRouteNextHopUri")) { + properties._advertisedRouteNextHopUri = 1; + if (!$util.isString(message.advertisedRouteNextHopUri)) + return "advertisedRouteNextHopUri: string expected"; } return null; }; /** - * Creates a LoadBalancerBackend message from a plain object. Also converts values to their respective internal types. + * Creates a RouteInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend + * @returns {google.cloud.networkmanagement.v1beta1.RouteInfo} RouteInfo */ - LoadBalancerBackend.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend) + RouteInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.RouteInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.uri != null) - message.uri = String(object.uri); - switch (object.healthCheckFirewallState) { + var message = new $root.google.cloud.networkmanagement.v1beta1.RouteInfo(); + switch (object.routeType) { default: - if (typeof object.healthCheckFirewallState === "number") { - message.healthCheckFirewallState = object.healthCheckFirewallState; + if (typeof object.routeType === "number") { + message.routeType = object.routeType; break; } break; - case "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED": + case "ROUTE_TYPE_UNSPECIFIED": case 0: - message.healthCheckFirewallState = 0; + message.routeType = 0; break; - case "CONFIGURED": + case "SUBNET": case 1: - message.healthCheckFirewallState = 1; + message.routeType = 1; break; - case "MISCONFIGURED": + case "STATIC": case 2: - message.healthCheckFirewallState = 2; + message.routeType = 2; + break; + case "DYNAMIC": + case 3: + message.routeType = 3; + break; + case "PEERING_SUBNET": + case 4: + message.routeType = 4; + break; + case "PEERING_STATIC": + case 5: + message.routeType = 5; + break; + case "PEERING_DYNAMIC": + case 6: + message.routeType = 6; + break; + case "POLICY_BASED": + case 7: + message.routeType = 7; + break; + case "ADVERTISED": + case 101: + message.routeType = 101; break; } - if (object.healthCheckAllowingFirewallRules) { - if (!Array.isArray(object.healthCheckAllowingFirewallRules)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.healthCheckAllowingFirewallRules: array expected"); - message.healthCheckAllowingFirewallRules = []; - for (var i = 0; i < object.healthCheckAllowingFirewallRules.length; ++i) - message.healthCheckAllowingFirewallRules[i] = String(object.healthCheckAllowingFirewallRules[i]); - } - if (object.healthCheckBlockingFirewallRules) { - if (!Array.isArray(object.healthCheckBlockingFirewallRules)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.healthCheckBlockingFirewallRules: array expected"); - message.healthCheckBlockingFirewallRules = []; - for (var i = 0; i < object.healthCheckBlockingFirewallRules.length; ++i) - message.healthCheckBlockingFirewallRules[i] = String(object.healthCheckBlockingFirewallRules[i]); + switch (object.nextHopType) { + default: + if (typeof object.nextHopType === "number") { + message.nextHopType = object.nextHopType; + break; + } + break; + case "NEXT_HOP_TYPE_UNSPECIFIED": + case 0: + message.nextHopType = 0; + break; + case "NEXT_HOP_IP": + case 1: + message.nextHopType = 1; + break; + case "NEXT_HOP_INSTANCE": + case 2: + message.nextHopType = 2; + break; + case "NEXT_HOP_NETWORK": + case 3: + message.nextHopType = 3; + break; + case "NEXT_HOP_PEERING": + case 4: + message.nextHopType = 4; + break; + case "NEXT_HOP_INTERCONNECT": + case 5: + message.nextHopType = 5; + break; + case "NEXT_HOP_VPN_TUNNEL": + case 6: + message.nextHopType = 6; + break; + case "NEXT_HOP_VPN_GATEWAY": + case 7: + message.nextHopType = 7; + break; + case "NEXT_HOP_INTERNET_GATEWAY": + case 8: + message.nextHopType = 8; + break; + case "NEXT_HOP_BLACKHOLE": + case 9: + message.nextHopType = 9; + break; + case "NEXT_HOP_ILB": + case 10: + message.nextHopType = 10; + break; + case "NEXT_HOP_ROUTER_APPLIANCE": + case 11: + message.nextHopType = 11; + break; + case "NEXT_HOP_NCC_HUB": + case 12: + message.nextHopType = 12; + break; } - return message; - }; - - /** - * Creates a plain object from a LoadBalancerBackend message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend - * @static - * @param {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} message LoadBalancerBackend - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - LoadBalancerBackend.toObject = function toObject(message, options) { + switch (object.routeScope) { + default: + if (typeof object.routeScope === "number") { + message.routeScope = object.routeScope; + break; + } + break; + case "ROUTE_SCOPE_UNSPECIFIED": + case 0: + message.routeScope = 0; + break; + case "NETWORK": + case 1: + message.routeScope = 1; + break; + case "NCC_HUB": + case 2: + message.routeScope = 2; + break; + } + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.region != null) + message.region = String(object.region); + if (object.destIpRange != null) + message.destIpRange = String(object.destIpRange); + if (object.nextHop != null) + message.nextHop = String(object.nextHop); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.priority != null) + message.priority = object.priority | 0; + if (object.instanceTags) { + if (!Array.isArray(object.instanceTags)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.instanceTags: array expected"); + message.instanceTags = []; + for (var i = 0; i < object.instanceTags.length; ++i) + message.instanceTags[i] = String(object.instanceTags[i]); + } + if (object.srcIpRange != null) + message.srcIpRange = String(object.srcIpRange); + if (object.destPortRanges) { + if (!Array.isArray(object.destPortRanges)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.destPortRanges: array expected"); + message.destPortRanges = []; + for (var i = 0; i < object.destPortRanges.length; ++i) + message.destPortRanges[i] = String(object.destPortRanges[i]); + } + if (object.srcPortRanges) { + if (!Array.isArray(object.srcPortRanges)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.srcPortRanges: array expected"); + message.srcPortRanges = []; + for (var i = 0; i < object.srcPortRanges.length; ++i) + message.srcPortRanges[i] = String(object.srcPortRanges[i]); + } + if (object.protocols) { + if (!Array.isArray(object.protocols)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.RouteInfo.protocols: array expected"); + message.protocols = []; + for (var i = 0; i < object.protocols.length; ++i) + message.protocols[i] = String(object.protocols[i]); + } + if (object.nccHubUri != null) + message.nccHubUri = String(object.nccHubUri); + if (object.nccSpokeUri != null) + message.nccSpokeUri = String(object.nccSpokeUri); + if (object.advertisedRouteSourceRouterUri != null) + message.advertisedRouteSourceRouterUri = String(object.advertisedRouteSourceRouterUri); + if (object.advertisedRouteNextHopUri != null) + message.advertisedRouteNextHopUri = String(object.advertisedRouteNextHopUri); + return message; + }; + + /** + * Creates a plain object from a RouteInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.RouteInfo} message RouteInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + RouteInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) { - object.healthCheckAllowingFirewallRules = []; - object.healthCheckBlockingFirewallRules = []; + object.instanceTags = []; + object.destPortRanges = []; + object.srcPortRanges = []; + object.protocols = []; } if (options.defaults) { object.displayName = ""; object.uri = ""; - object.healthCheckFirewallState = options.enums === String ? "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED" : 0; + object.destIpRange = ""; + object.nextHop = ""; + object.networkUri = ""; + object.priority = 0; + object.routeType = options.enums === String ? "ROUTE_TYPE_UNSPECIFIED" : 0; + object.nextHopType = options.enums === String ? "NEXT_HOP_TYPE_UNSPECIFIED" : 0; + object.srcIpRange = ""; + object.routeScope = options.enums === String ? "ROUTE_SCOPE_UNSPECIFIED" : 0; + object.region = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.healthCheckFirewallState != null && message.hasOwnProperty("healthCheckFirewallState")) - object.healthCheckFirewallState = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState[message.healthCheckFirewallState] === undefined ? message.healthCheckFirewallState : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState[message.healthCheckFirewallState] : message.healthCheckFirewallState; - if (message.healthCheckAllowingFirewallRules && message.healthCheckAllowingFirewallRules.length) { - object.healthCheckAllowingFirewallRules = []; - for (var j = 0; j < message.healthCheckAllowingFirewallRules.length; ++j) - object.healthCheckAllowingFirewallRules[j] = message.healthCheckAllowingFirewallRules[j]; + if (message.destIpRange != null && message.hasOwnProperty("destIpRange")) + object.destIpRange = message.destIpRange; + if (message.nextHop != null && message.hasOwnProperty("nextHop")) + object.nextHop = message.nextHop; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.priority != null && message.hasOwnProperty("priority")) + object.priority = message.priority; + if (message.instanceTags && message.instanceTags.length) { + object.instanceTags = []; + for (var j = 0; j < message.instanceTags.length; ++j) + object.instanceTags[j] = message.instanceTags[j]; } - if (message.healthCheckBlockingFirewallRules && message.healthCheckBlockingFirewallRules.length) { - object.healthCheckBlockingFirewallRules = []; - for (var j = 0; j < message.healthCheckBlockingFirewallRules.length; ++j) - object.healthCheckBlockingFirewallRules[j] = message.healthCheckBlockingFirewallRules[j]; + if (message.routeType != null && message.hasOwnProperty("routeType")) + object.routeType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType[message.routeType] === undefined ? message.routeType : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType[message.routeType] : message.routeType; + if (message.nextHopType != null && message.hasOwnProperty("nextHopType")) + object.nextHopType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType[message.nextHopType] === undefined ? message.nextHopType : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType[message.nextHopType] : message.nextHopType; + if (message.srcIpRange != null && message.hasOwnProperty("srcIpRange")) + object.srcIpRange = message.srcIpRange; + if (message.destPortRanges && message.destPortRanges.length) { + object.destPortRanges = []; + for (var j = 0; j < message.destPortRanges.length; ++j) + object.destPortRanges[j] = message.destPortRanges[j]; + } + if (message.srcPortRanges && message.srcPortRanges.length) { + object.srcPortRanges = []; + for (var j = 0; j < message.srcPortRanges.length; ++j) + object.srcPortRanges[j] = message.srcPortRanges[j]; + } + if (message.protocols && message.protocols.length) { + object.protocols = []; + for (var j = 0; j < message.protocols.length; ++j) + object.protocols[j] = message.protocols[j]; + } + if (message.routeScope != null && message.hasOwnProperty("routeScope")) + object.routeScope = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope[message.routeScope] === undefined ? message.routeScope : $root.google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope[message.routeScope] : message.routeScope; + if (message.nccHubUri != null && message.hasOwnProperty("nccHubUri")) { + object.nccHubUri = message.nccHubUri; + if (options.oneofs) + object._nccHubUri = "nccHubUri"; + } + if (message.nccSpokeUri != null && message.hasOwnProperty("nccSpokeUri")) { + object.nccSpokeUri = message.nccSpokeUri; + if (options.oneofs) + object._nccSpokeUri = "nccSpokeUri"; + } + if (message.advertisedRouteSourceRouterUri != null && message.hasOwnProperty("advertisedRouteSourceRouterUri")) { + object.advertisedRouteSourceRouterUri = message.advertisedRouteSourceRouterUri; + if (options.oneofs) + object._advertisedRouteSourceRouterUri = "advertisedRouteSourceRouterUri"; + } + if (message.advertisedRouteNextHopUri != null && message.hasOwnProperty("advertisedRouteNextHopUri")) { + object.advertisedRouteNextHopUri = message.advertisedRouteNextHopUri; + if (options.oneofs) + object._advertisedRouteNextHopUri = "advertisedRouteNextHopUri"; } + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; /** - * Converts this LoadBalancerBackend to JSON. + * Converts this RouteInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @instance * @returns {Object.} JSON object */ - LoadBalancerBackend.prototype.toJSON = function toJSON() { + RouteInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for LoadBalancerBackend + * Gets the default type url for RouteInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @memberof google.cloud.networkmanagement.v1beta1.RouteInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - LoadBalancerBackend.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RouteInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LoadBalancerBackend"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.RouteInfo"; }; /** - * HealthCheckFirewallState enum. - * @name google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState + * RouteType enum. + * @name google.cloud.networkmanagement.v1beta1.RouteInfo.RouteType * @enum {number} - * @property {number} HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED=0 HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED value - * @property {number} CONFIGURED=1 CONFIGURED value - * @property {number} MISCONFIGURED=2 MISCONFIGURED value + * @property {number} ROUTE_TYPE_UNSPECIFIED=0 ROUTE_TYPE_UNSPECIFIED value + * @property {number} SUBNET=1 SUBNET value + * @property {number} STATIC=2 STATIC value + * @property {number} DYNAMIC=3 DYNAMIC value + * @property {number} PEERING_SUBNET=4 PEERING_SUBNET value + * @property {number} PEERING_STATIC=5 PEERING_STATIC value + * @property {number} PEERING_DYNAMIC=6 PEERING_DYNAMIC value + * @property {number} POLICY_BASED=7 POLICY_BASED value + * @property {number} ADVERTISED=101 ADVERTISED value */ - LoadBalancerBackend.HealthCheckFirewallState = (function() { + RouteInfo.RouteType = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED"] = 0; - values[valuesById[1] = "CONFIGURED"] = 1; - values[valuesById[2] = "MISCONFIGURED"] = 2; + values[valuesById[0] = "ROUTE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "SUBNET"] = 1; + values[valuesById[2] = "STATIC"] = 2; + values[valuesById[3] = "DYNAMIC"] = 3; + values[valuesById[4] = "PEERING_SUBNET"] = 4; + values[valuesById[5] = "PEERING_STATIC"] = 5; + values[valuesById[6] = "PEERING_DYNAMIC"] = 6; + values[valuesById[7] = "POLICY_BASED"] = 7; + values[valuesById[101] = "ADVERTISED"] = 101; return values; })(); - return LoadBalancerBackend; - })(); - - v1beta1.VpnGatewayInfo = (function() { - /** - * Properties of a VpnGatewayInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IVpnGatewayInfo - * @property {string|null} [displayName] VpnGatewayInfo displayName - * @property {string|null} [uri] VpnGatewayInfo uri - * @property {string|null} [networkUri] VpnGatewayInfo networkUri - * @property {string|null} [ipAddress] VpnGatewayInfo ipAddress - * @property {string|null} [vpnTunnelUri] VpnGatewayInfo vpnTunnelUri - * @property {string|null} [region] VpnGatewayInfo region + * NextHopType enum. + * @name google.cloud.networkmanagement.v1beta1.RouteInfo.NextHopType + * @enum {number} + * @property {number} NEXT_HOP_TYPE_UNSPECIFIED=0 NEXT_HOP_TYPE_UNSPECIFIED value + * @property {number} NEXT_HOP_IP=1 NEXT_HOP_IP value + * @property {number} NEXT_HOP_INSTANCE=2 NEXT_HOP_INSTANCE value + * @property {number} NEXT_HOP_NETWORK=3 NEXT_HOP_NETWORK value + * @property {number} NEXT_HOP_PEERING=4 NEXT_HOP_PEERING value + * @property {number} NEXT_HOP_INTERCONNECT=5 NEXT_HOP_INTERCONNECT value + * @property {number} NEXT_HOP_VPN_TUNNEL=6 NEXT_HOP_VPN_TUNNEL value + * @property {number} NEXT_HOP_VPN_GATEWAY=7 NEXT_HOP_VPN_GATEWAY value + * @property {number} NEXT_HOP_INTERNET_GATEWAY=8 NEXT_HOP_INTERNET_GATEWAY value + * @property {number} NEXT_HOP_BLACKHOLE=9 NEXT_HOP_BLACKHOLE value + * @property {number} NEXT_HOP_ILB=10 NEXT_HOP_ILB value + * @property {number} NEXT_HOP_ROUTER_APPLIANCE=11 NEXT_HOP_ROUTER_APPLIANCE value + * @property {number} NEXT_HOP_NCC_HUB=12 NEXT_HOP_NCC_HUB value */ + RouteInfo.NextHopType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "NEXT_HOP_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "NEXT_HOP_IP"] = 1; + values[valuesById[2] = "NEXT_HOP_INSTANCE"] = 2; + values[valuesById[3] = "NEXT_HOP_NETWORK"] = 3; + values[valuesById[4] = "NEXT_HOP_PEERING"] = 4; + values[valuesById[5] = "NEXT_HOP_INTERCONNECT"] = 5; + values[valuesById[6] = "NEXT_HOP_VPN_TUNNEL"] = 6; + values[valuesById[7] = "NEXT_HOP_VPN_GATEWAY"] = 7; + values[valuesById[8] = "NEXT_HOP_INTERNET_GATEWAY"] = 8; + values[valuesById[9] = "NEXT_HOP_BLACKHOLE"] = 9; + values[valuesById[10] = "NEXT_HOP_ILB"] = 10; + values[valuesById[11] = "NEXT_HOP_ROUTER_APPLIANCE"] = 11; + values[valuesById[12] = "NEXT_HOP_NCC_HUB"] = 12; + return values; + })(); /** - * Constructs a new VpnGatewayInfo. - * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a VpnGatewayInfo. - * @implements IVpnGatewayInfo - * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo=} [properties] Properties to set - */ - function VpnGatewayInfo(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * VpnGatewayInfo displayName. - * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo - * @instance + * RouteScope enum. + * @name google.cloud.networkmanagement.v1beta1.RouteInfo.RouteScope + * @enum {number} + * @property {number} ROUTE_SCOPE_UNSPECIFIED=0 ROUTE_SCOPE_UNSPECIFIED value + * @property {number} NETWORK=1 NETWORK value + * @property {number} NCC_HUB=2 NCC_HUB value */ - VpnGatewayInfo.prototype.displayName = ""; + RouteInfo.RouteScope = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "ROUTE_SCOPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "NETWORK"] = 1; + values[valuesById[2] = "NCC_HUB"] = 2; + return values; + })(); - /** - * VpnGatewayInfo uri. - * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo - * @instance - */ - VpnGatewayInfo.prototype.uri = ""; + return RouteInfo; + })(); + + v1beta1.GoogleServiceInfo = (function() { /** - * VpnGatewayInfo networkUri. - * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo - * @instance + * Properties of a GoogleServiceInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IGoogleServiceInfo + * @property {string|null} [sourceIp] GoogleServiceInfo sourceIp + * @property {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType|null} [googleServiceType] GoogleServiceInfo googleServiceType */ - VpnGatewayInfo.prototype.networkUri = ""; /** - * VpnGatewayInfo ipAddress. - * @member {string} ipAddress - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo - * @instance + * Constructs a new GoogleServiceInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a GoogleServiceInfo. + * @implements IGoogleServiceInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo=} [properties] Properties to set */ - VpnGatewayInfo.prototype.ipAddress = ""; + function GoogleServiceInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * VpnGatewayInfo vpnTunnelUri. - * @member {string} vpnTunnelUri - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * GoogleServiceInfo sourceIp. + * @member {string} sourceIp + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @instance */ - VpnGatewayInfo.prototype.vpnTunnelUri = ""; + GoogleServiceInfo.prototype.sourceIp = ""; /** - * VpnGatewayInfo region. - * @member {string} region - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * GoogleServiceInfo googleServiceType. + * @member {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType} googleServiceType + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @instance */ - VpnGatewayInfo.prototype.region = ""; + GoogleServiceInfo.prototype.googleServiceType = 0; /** - * Creates a new VpnGatewayInfo instance using the specified properties. + * Creates a new GoogleServiceInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo instance */ - VpnGatewayInfo.create = function create(properties) { - return new VpnGatewayInfo(properties); + GoogleServiceInfo.create = function create(properties) { + return new GoogleServiceInfo(properties); }; /** - * Encodes the specified VpnGatewayInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify|verify} messages. + * Encodes the specified GoogleServiceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo} message VpnGatewayInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo} message GoogleServiceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpnGatewayInfo.encode = function encode(message, writer) { + GoogleServiceInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); - if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.ipAddress); - if (message.vpnTunnelUri != null && Object.hasOwnProperty.call(message, "vpnTunnelUri")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.vpnTunnelUri); - if (message.region != null && Object.hasOwnProperty.call(message, "region")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); + if (message.sourceIp != null && Object.hasOwnProperty.call(message, "sourceIp")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.sourceIp); + if (message.googleServiceType != null && Object.hasOwnProperty.call(message, "googleServiceType")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.googleServiceType); return writer; }; /** - * Encodes the specified VpnGatewayInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify|verify} messages. + * Encodes the specified GoogleServiceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo} message VpnGatewayInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IGoogleServiceInfo} message GoogleServiceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpnGatewayInfo.encodeDelimited = function encodeDelimited(message, writer) { + GoogleServiceInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a VpnGatewayInfo message from the specified reader or buffer. + * Decodes a GoogleServiceInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo + * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpnGatewayInfo.decode = function decode(reader, length) { + GoogleServiceInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); + message.sourceIp = reader.string(); break; } case 2: { - message.uri = reader.string(); - break; - } - case 3: { - message.networkUri = reader.string(); - break; - } - case 4: { - message.ipAddress = reader.string(); - break; - } - case 5: { - message.vpnTunnelUri = reader.string(); - break; - } - case 6: { - message.region = reader.string(); + message.googleServiceType = reader.int32(); break; } default: @@ -26089,171 +26525,209 @@ }; /** - * Decodes a VpnGatewayInfo message from the specified reader or buffer, length delimited. + * Decodes a GoogleServiceInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo + * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpnGatewayInfo.decodeDelimited = function decodeDelimited(reader) { + GoogleServiceInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a VpnGatewayInfo message. + * Verifies a GoogleServiceInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - VpnGatewayInfo.verify = function verify(message) { + GoogleServiceInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.uri != null && message.hasOwnProperty("uri")) - if (!$util.isString(message.uri)) - return "uri: string expected"; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - if (!$util.isString(message.networkUri)) - return "networkUri: string expected"; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - if (!$util.isString(message.ipAddress)) - return "ipAddress: string expected"; - if (message.vpnTunnelUri != null && message.hasOwnProperty("vpnTunnelUri")) - if (!$util.isString(message.vpnTunnelUri)) - return "vpnTunnelUri: string expected"; - if (message.region != null && message.hasOwnProperty("region")) - if (!$util.isString(message.region)) - return "region: string expected"; + if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) + if (!$util.isString(message.sourceIp)) + return "sourceIp: string expected"; + if (message.googleServiceType != null && message.hasOwnProperty("googleServiceType")) + switch (message.googleServiceType) { + default: + return "googleServiceType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + break; + } return null; }; /** - * Creates a VpnGatewayInfo message from a plain object. Also converts values to their respective internal types. + * Creates a GoogleServiceInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo + * @returns {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} GoogleServiceInfo */ - VpnGatewayInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo) + GoogleServiceInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.uri != null) - message.uri = String(object.uri); - if (object.networkUri != null) - message.networkUri = String(object.networkUri); - if (object.ipAddress != null) - message.ipAddress = String(object.ipAddress); - if (object.vpnTunnelUri != null) - message.vpnTunnelUri = String(object.vpnTunnelUri); - if (object.region != null) - message.region = String(object.region); - return message; - }; - - /** - * Creates a plain object from a VpnGatewayInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} message VpnGatewayInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - VpnGatewayInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.displayName = ""; - object.uri = ""; - object.networkUri = ""; - object.ipAddress = ""; - object.vpnTunnelUri = ""; - object.region = ""; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.uri != null && message.hasOwnProperty("uri")) - object.uri = message.uri; - if (message.networkUri != null && message.hasOwnProperty("networkUri")) - object.networkUri = message.networkUri; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - object.ipAddress = message.ipAddress; - if (message.vpnTunnelUri != null && message.hasOwnProperty("vpnTunnelUri")) - object.vpnTunnelUri = message.vpnTunnelUri; - if (message.region != null && message.hasOwnProperty("region")) - object.region = message.region; + var message = new $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo(); + if (object.sourceIp != null) + message.sourceIp = String(object.sourceIp); + switch (object.googleServiceType) { + default: + if (typeof object.googleServiceType === "number") { + message.googleServiceType = object.googleServiceType; + break; + } + break; + case "GOOGLE_SERVICE_TYPE_UNSPECIFIED": + case 0: + message.googleServiceType = 0; + break; + case "IAP": + case 1: + message.googleServiceType = 1; + break; + case "GFE_PROXY_OR_HEALTH_CHECK_PROBER": + case 2: + message.googleServiceType = 2; + break; + case "CLOUD_DNS": + case 3: + message.googleServiceType = 3; + break; + case "GOOGLE_API": + case 4: + message.googleServiceType = 4; + break; + case "GOOGLE_API_PSC": + case 5: + message.googleServiceType = 5; + break; + case "GOOGLE_API_VPC_SC": + case 6: + message.googleServiceType = 6; + break; + } + return message; + }; + + /** + * Creates a plain object from a GoogleServiceInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.GoogleServiceInfo} message GoogleServiceInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GoogleServiceInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.sourceIp = ""; + object.googleServiceType = options.enums === String ? "GOOGLE_SERVICE_TYPE_UNSPECIFIED" : 0; + } + if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) + object.sourceIp = message.sourceIp; + if (message.googleServiceType != null && message.hasOwnProperty("googleServiceType")) + object.googleServiceType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType[message.googleServiceType] === undefined ? message.googleServiceType : $root.google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType[message.googleServiceType] : message.googleServiceType; return object; }; /** - * Converts this VpnGatewayInfo to JSON. + * Converts this GoogleServiceInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @instance * @returns {Object.} JSON object */ - VpnGatewayInfo.prototype.toJSON = function toJSON() { + GoogleServiceInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for VpnGatewayInfo + * Gets the default type url for GoogleServiceInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @memberof google.cloud.networkmanagement.v1beta1.GoogleServiceInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - VpnGatewayInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GoogleServiceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.VpnGatewayInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.GoogleServiceInfo"; }; - return VpnGatewayInfo; + /** + * GoogleServiceType enum. + * @name google.cloud.networkmanagement.v1beta1.GoogleServiceInfo.GoogleServiceType + * @enum {number} + * @property {number} GOOGLE_SERVICE_TYPE_UNSPECIFIED=0 GOOGLE_SERVICE_TYPE_UNSPECIFIED value + * @property {number} IAP=1 IAP value + * @property {number} GFE_PROXY_OR_HEALTH_CHECK_PROBER=2 GFE_PROXY_OR_HEALTH_CHECK_PROBER value + * @property {number} CLOUD_DNS=3 CLOUD_DNS value + * @property {number} GOOGLE_API=4 GOOGLE_API value + * @property {number} GOOGLE_API_PSC=5 GOOGLE_API_PSC value + * @property {number} GOOGLE_API_VPC_SC=6 GOOGLE_API_VPC_SC value + */ + GoogleServiceInfo.GoogleServiceType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "GOOGLE_SERVICE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "IAP"] = 1; + values[valuesById[2] = "GFE_PROXY_OR_HEALTH_CHECK_PROBER"] = 2; + values[valuesById[3] = "CLOUD_DNS"] = 3; + values[valuesById[4] = "GOOGLE_API"] = 4; + values[valuesById[5] = "GOOGLE_API_PSC"] = 5; + values[valuesById[6] = "GOOGLE_API_VPC_SC"] = 6; + return values; + })(); + + return GoogleServiceInfo; })(); - v1beta1.VpnTunnelInfo = (function() { + v1beta1.ForwardingRuleInfo = (function() { /** - * Properties of a VpnTunnelInfo. + * Properties of a ForwardingRuleInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IVpnTunnelInfo - * @property {string|null} [displayName] VpnTunnelInfo displayName - * @property {string|null} [uri] VpnTunnelInfo uri - * @property {string|null} [sourceGateway] VpnTunnelInfo sourceGateway - * @property {string|null} [remoteGateway] VpnTunnelInfo remoteGateway - * @property {string|null} [remoteGatewayIp] VpnTunnelInfo remoteGatewayIp - * @property {string|null} [sourceGatewayIp] VpnTunnelInfo sourceGatewayIp - * @property {string|null} [networkUri] VpnTunnelInfo networkUri - * @property {string|null} [region] VpnTunnelInfo region - * @property {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType|null} [routingType] VpnTunnelInfo routingType + * @interface IForwardingRuleInfo + * @property {string|null} [displayName] ForwardingRuleInfo displayName + * @property {string|null} [uri] ForwardingRuleInfo uri + * @property {string|null} [matchedProtocol] ForwardingRuleInfo matchedProtocol + * @property {string|null} [matchedPortRange] ForwardingRuleInfo matchedPortRange + * @property {string|null} [vip] ForwardingRuleInfo vip + * @property {string|null} [target] ForwardingRuleInfo target + * @property {string|null} [networkUri] ForwardingRuleInfo networkUri + * @property {string|null} [region] ForwardingRuleInfo region + * @property {string|null} [loadBalancerName] ForwardingRuleInfo loadBalancerName + * @property {string|null} [pscServiceAttachmentUri] ForwardingRuleInfo pscServiceAttachmentUri + * @property {string|null} [pscGoogleApiTarget] ForwardingRuleInfo pscGoogleApiTarget */ /** - * Constructs a new VpnTunnelInfo. + * Constructs a new ForwardingRuleInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a VpnTunnelInfo. - * @implements IVpnTunnelInfo + * @classdesc Represents a ForwardingRuleInfo. + * @implements IForwardingRuleInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo=} [properties] Properties to set */ - function VpnTunnelInfo(properties) { + function ForwardingRuleInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26261,150 +26735,170 @@ } /** - * VpnTunnelInfo displayName. + * ForwardingRuleInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.displayName = ""; + ForwardingRuleInfo.prototype.displayName = ""; /** - * VpnTunnelInfo uri. + * ForwardingRuleInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.uri = ""; + ForwardingRuleInfo.prototype.uri = ""; /** - * VpnTunnelInfo sourceGateway. - * @member {string} sourceGateway - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * ForwardingRuleInfo matchedProtocol. + * @member {string} matchedProtocol + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.sourceGateway = ""; + ForwardingRuleInfo.prototype.matchedProtocol = ""; /** - * VpnTunnelInfo remoteGateway. - * @member {string} remoteGateway - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * ForwardingRuleInfo matchedPortRange. + * @member {string} matchedPortRange + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.remoteGateway = ""; + ForwardingRuleInfo.prototype.matchedPortRange = ""; /** - * VpnTunnelInfo remoteGatewayIp. - * @member {string} remoteGatewayIp - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * ForwardingRuleInfo vip. + * @member {string} vip + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.remoteGatewayIp = ""; + ForwardingRuleInfo.prototype.vip = ""; /** - * VpnTunnelInfo sourceGatewayIp. - * @member {string} sourceGatewayIp - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * ForwardingRuleInfo target. + * @member {string} target + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.sourceGatewayIp = ""; + ForwardingRuleInfo.prototype.target = ""; /** - * VpnTunnelInfo networkUri. + * ForwardingRuleInfo networkUri. * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.networkUri = ""; + ForwardingRuleInfo.prototype.networkUri = ""; /** - * VpnTunnelInfo region. + * ForwardingRuleInfo region. * @member {string} region - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.region = ""; + ForwardingRuleInfo.prototype.region = ""; /** - * VpnTunnelInfo routingType. - * @member {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType} routingType - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * ForwardingRuleInfo loadBalancerName. + * @member {string} loadBalancerName + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance */ - VpnTunnelInfo.prototype.routingType = 0; + ForwardingRuleInfo.prototype.loadBalancerName = ""; /** - * Creates a new VpnTunnelInfo instance using the specified properties. + * ForwardingRuleInfo pscServiceAttachmentUri. + * @member {string} pscServiceAttachmentUri + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.pscServiceAttachmentUri = ""; + + /** + * ForwardingRuleInfo pscGoogleApiTarget. + * @member {string} pscGoogleApiTarget + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo + * @instance + */ + ForwardingRuleInfo.prototype.pscGoogleApiTarget = ""; + + /** + * Creates a new ForwardingRuleInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo instance */ - VpnTunnelInfo.create = function create(properties) { - return new VpnTunnelInfo(properties); + ForwardingRuleInfo.create = function create(properties) { + return new ForwardingRuleInfo(properties); }; /** - * Encodes the specified VpnTunnelInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify|verify} messages. + * Encodes the specified ForwardingRuleInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo} message VpnTunnelInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo} message ForwardingRuleInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpnTunnelInfo.encode = function encode(message, writer) { + ForwardingRuleInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); - if (message.sourceGateway != null && Object.hasOwnProperty.call(message, "sourceGateway")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.sourceGateway); - if (message.remoteGateway != null && Object.hasOwnProperty.call(message, "remoteGateway")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.remoteGateway); - if (message.remoteGatewayIp != null && Object.hasOwnProperty.call(message, "remoteGatewayIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.remoteGatewayIp); - if (message.sourceGatewayIp != null && Object.hasOwnProperty.call(message, "sourceGatewayIp")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.sourceGatewayIp); + if (message.matchedProtocol != null && Object.hasOwnProperty.call(message, "matchedProtocol")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.matchedProtocol); + if (message.vip != null && Object.hasOwnProperty.call(message, "vip")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.vip); + if (message.target != null && Object.hasOwnProperty.call(message, "target")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.target); + if (message.matchedPortRange != null && Object.hasOwnProperty.call(message, "matchedPortRange")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.matchedPortRange); if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkUri); if (message.region != null && Object.hasOwnProperty.call(message, "region")) writer.uint32(/* id 8, wireType 2 =*/66).string(message.region); - if (message.routingType != null && Object.hasOwnProperty.call(message, "routingType")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.routingType); + if (message.loadBalancerName != null && Object.hasOwnProperty.call(message, "loadBalancerName")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.loadBalancerName); + if (message.pscServiceAttachmentUri != null && Object.hasOwnProperty.call(message, "pscServiceAttachmentUri")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.pscServiceAttachmentUri); + if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.pscGoogleApiTarget); return writer; }; /** - * Encodes the specified VpnTunnelInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify|verify} messages. + * Encodes the specified ForwardingRuleInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo} message VpnTunnelInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IForwardingRuleInfo} message ForwardingRuleInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VpnTunnelInfo.encodeDelimited = function encodeDelimited(message, writer) { + ForwardingRuleInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a VpnTunnelInfo message from the specified reader or buffer. + * Decodes a ForwardingRuleInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo + * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpnTunnelInfo.decode = function decode(reader, length) { + ForwardingRuleInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -26417,19 +26911,19 @@ break; } case 3: { - message.sourceGateway = reader.string(); + message.matchedProtocol = reader.string(); break; } - case 4: { - message.remoteGateway = reader.string(); + case 6: { + message.matchedPortRange = reader.string(); break; } - case 5: { - message.remoteGatewayIp = reader.string(); + case 4: { + message.vip = reader.string(); break; } - case 6: { - message.sourceGatewayIp = reader.string(); + case 5: { + message.target = reader.string(); break; } case 7: { @@ -26441,7 +26935,15 @@ break; } case 9: { - message.routingType = reader.int32(); + message.loadBalancerName = reader.string(); + break; + } + case 10: { + message.pscServiceAttachmentUri = reader.string(); + break; + } + case 11: { + message.pscGoogleApiTarget = reader.string(); break; } default: @@ -26453,30 +26955,30 @@ }; /** - * Decodes a VpnTunnelInfo message from the specified reader or buffer, length delimited. + * Decodes a ForwardingRuleInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo + * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VpnTunnelInfo.decodeDelimited = function decodeDelimited(reader) { + ForwardingRuleInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a VpnTunnelInfo message. + * Verifies a ForwardingRuleInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - VpnTunnelInfo.verify = function verify(message) { + ForwardingRuleInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -26485,209 +26987,176 @@ if (message.uri != null && message.hasOwnProperty("uri")) if (!$util.isString(message.uri)) return "uri: string expected"; - if (message.sourceGateway != null && message.hasOwnProperty("sourceGateway")) - if (!$util.isString(message.sourceGateway)) - return "sourceGateway: string expected"; - if (message.remoteGateway != null && message.hasOwnProperty("remoteGateway")) - if (!$util.isString(message.remoteGateway)) - return "remoteGateway: string expected"; - if (message.remoteGatewayIp != null && message.hasOwnProperty("remoteGatewayIp")) - if (!$util.isString(message.remoteGatewayIp)) - return "remoteGatewayIp: string expected"; - if (message.sourceGatewayIp != null && message.hasOwnProperty("sourceGatewayIp")) - if (!$util.isString(message.sourceGatewayIp)) - return "sourceGatewayIp: string expected"; + if (message.matchedProtocol != null && message.hasOwnProperty("matchedProtocol")) + if (!$util.isString(message.matchedProtocol)) + return "matchedProtocol: string expected"; + if (message.matchedPortRange != null && message.hasOwnProperty("matchedPortRange")) + if (!$util.isString(message.matchedPortRange)) + return "matchedPortRange: string expected"; + if (message.vip != null && message.hasOwnProperty("vip")) + if (!$util.isString(message.vip)) + return "vip: string expected"; + if (message.target != null && message.hasOwnProperty("target")) + if (!$util.isString(message.target)) + return "target: string expected"; if (message.networkUri != null && message.hasOwnProperty("networkUri")) if (!$util.isString(message.networkUri)) return "networkUri: string expected"; if (message.region != null && message.hasOwnProperty("region")) if (!$util.isString(message.region)) return "region: string expected"; - if (message.routingType != null && message.hasOwnProperty("routingType")) - switch (message.routingType) { - default: - return "routingType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } + if (message.loadBalancerName != null && message.hasOwnProperty("loadBalancerName")) + if (!$util.isString(message.loadBalancerName)) + return "loadBalancerName: string expected"; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + if (!$util.isString(message.pscServiceAttachmentUri)) + return "pscServiceAttachmentUri: string expected"; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + if (!$util.isString(message.pscGoogleApiTarget)) + return "pscGoogleApiTarget: string expected"; return null; }; /** - * Creates a VpnTunnelInfo message from a plain object. Also converts values to their respective internal types. + * Creates a ForwardingRuleInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo + * @returns {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} ForwardingRuleInfo */ - VpnTunnelInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo) + ForwardingRuleInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo(); + var message = new $root.google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); - if (object.sourceGateway != null) - message.sourceGateway = String(object.sourceGateway); - if (object.remoteGateway != null) - message.remoteGateway = String(object.remoteGateway); - if (object.remoteGatewayIp != null) - message.remoteGatewayIp = String(object.remoteGatewayIp); - if (object.sourceGatewayIp != null) - message.sourceGatewayIp = String(object.sourceGatewayIp); + if (object.matchedProtocol != null) + message.matchedProtocol = String(object.matchedProtocol); + if (object.matchedPortRange != null) + message.matchedPortRange = String(object.matchedPortRange); + if (object.vip != null) + message.vip = String(object.vip); + if (object.target != null) + message.target = String(object.target); if (object.networkUri != null) message.networkUri = String(object.networkUri); if (object.region != null) message.region = String(object.region); - switch (object.routingType) { - default: - if (typeof object.routingType === "number") { - message.routingType = object.routingType; - break; - } - break; - case "ROUTING_TYPE_UNSPECIFIED": - case 0: - message.routingType = 0; - break; - case "ROUTE_BASED": - case 1: - message.routingType = 1; - break; - case "POLICY_BASED": - case 2: - message.routingType = 2; - break; - case "DYNAMIC": - case 3: - message.routingType = 3; - break; - } + if (object.loadBalancerName != null) + message.loadBalancerName = String(object.loadBalancerName); + if (object.pscServiceAttachmentUri != null) + message.pscServiceAttachmentUri = String(object.pscServiceAttachmentUri); + if (object.pscGoogleApiTarget != null) + message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); return message; }; /** - * Creates a plain object from a VpnTunnelInfo message. Also converts values to other types if specified. + * Creates a plain object from a ForwardingRuleInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} message VpnTunnelInfo + * @param {google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo} message ForwardingRuleInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - VpnTunnelInfo.toObject = function toObject(message, options) { + ForwardingRuleInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.displayName = ""; object.uri = ""; - object.sourceGateway = ""; - object.remoteGateway = ""; - object.remoteGatewayIp = ""; - object.sourceGatewayIp = ""; + object.matchedProtocol = ""; + object.vip = ""; + object.target = ""; + object.matchedPortRange = ""; object.networkUri = ""; object.region = ""; - object.routingType = options.enums === String ? "ROUTING_TYPE_UNSPECIFIED" : 0; + object.loadBalancerName = ""; + object.pscServiceAttachmentUri = ""; + object.pscGoogleApiTarget = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.uri != null && message.hasOwnProperty("uri")) object.uri = message.uri; - if (message.sourceGateway != null && message.hasOwnProperty("sourceGateway")) - object.sourceGateway = message.sourceGateway; - if (message.remoteGateway != null && message.hasOwnProperty("remoteGateway")) - object.remoteGateway = message.remoteGateway; - if (message.remoteGatewayIp != null && message.hasOwnProperty("remoteGatewayIp")) - object.remoteGatewayIp = message.remoteGatewayIp; - if (message.sourceGatewayIp != null && message.hasOwnProperty("sourceGatewayIp")) - object.sourceGatewayIp = message.sourceGatewayIp; + if (message.matchedProtocol != null && message.hasOwnProperty("matchedProtocol")) + object.matchedProtocol = message.matchedProtocol; + if (message.vip != null && message.hasOwnProperty("vip")) + object.vip = message.vip; + if (message.target != null && message.hasOwnProperty("target")) + object.target = message.target; + if (message.matchedPortRange != null && message.hasOwnProperty("matchedPortRange")) + object.matchedPortRange = message.matchedPortRange; if (message.networkUri != null && message.hasOwnProperty("networkUri")) object.networkUri = message.networkUri; if (message.region != null && message.hasOwnProperty("region")) object.region = message.region; - if (message.routingType != null && message.hasOwnProperty("routingType")) - object.routingType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType[message.routingType] === undefined ? message.routingType : $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType[message.routingType] : message.routingType; + if (message.loadBalancerName != null && message.hasOwnProperty("loadBalancerName")) + object.loadBalancerName = message.loadBalancerName; + if (message.pscServiceAttachmentUri != null && message.hasOwnProperty("pscServiceAttachmentUri")) + object.pscServiceAttachmentUri = message.pscServiceAttachmentUri; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + object.pscGoogleApiTarget = message.pscGoogleApiTarget; return object; }; /** - * Converts this VpnTunnelInfo to JSON. + * Converts this ForwardingRuleInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @instance * @returns {Object.} JSON object */ - VpnTunnelInfo.prototype.toJSON = function toJSON() { + ForwardingRuleInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for VpnTunnelInfo + * Gets the default type url for ForwardingRuleInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @memberof google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - VpnTunnelInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ForwardingRuleInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.VpnTunnelInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ForwardingRuleInfo"; }; - /** - * RoutingType enum. - * @name google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType - * @enum {number} - * @property {number} ROUTING_TYPE_UNSPECIFIED=0 ROUTING_TYPE_UNSPECIFIED value - * @property {number} ROUTE_BASED=1 ROUTE_BASED value - * @property {number} POLICY_BASED=2 POLICY_BASED value - * @property {number} DYNAMIC=3 DYNAMIC value - */ - VpnTunnelInfo.RoutingType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ROUTING_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "ROUTE_BASED"] = 1; - values[valuesById[2] = "POLICY_BASED"] = 2; - values[valuesById[3] = "DYNAMIC"] = 3; - return values; - })(); - - return VpnTunnelInfo; + return ForwardingRuleInfo; })(); - v1beta1.EndpointInfo = (function() { + v1beta1.LoadBalancerInfo = (function() { /** - * Properties of an EndpointInfo. + * Properties of a LoadBalancerInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IEndpointInfo - * @property {string|null} [sourceIp] EndpointInfo sourceIp - * @property {string|null} [destinationIp] EndpointInfo destinationIp - * @property {string|null} [protocol] EndpointInfo protocol - * @property {number|null} [sourcePort] EndpointInfo sourcePort - * @property {number|null} [destinationPort] EndpointInfo destinationPort - * @property {string|null} [sourceNetworkUri] EndpointInfo sourceNetworkUri - * @property {string|null} [destinationNetworkUri] EndpointInfo destinationNetworkUri - * @property {string|null} [sourceAgentUri] EndpointInfo sourceAgentUri + * @interface ILoadBalancerInfo + * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType|null} [loadBalancerType] LoadBalancerInfo loadBalancerType + * @property {string|null} [healthCheckUri] LoadBalancerInfo healthCheckUri + * @property {Array.|null} [backends] LoadBalancerInfo backends + * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType|null} [backendType] LoadBalancerInfo backendType + * @property {string|null} [backendUri] LoadBalancerInfo backendUri */ /** - * Constructs a new EndpointInfo. + * Constructs a new LoadBalancerInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents an EndpointInfo. - * @implements IEndpointInfo + * @classdesc Represents a LoadBalancerInfo. + * @implements ILoadBalancerInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo=} [properties] Properties to set */ - function EndpointInfo(properties) { + function LoadBalancerInfo(properties) { + this.backends = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26695,173 +27164,134 @@ } /** - * EndpointInfo sourceIp. - * @member {string} sourceIp - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * LoadBalancerInfo loadBalancerType. + * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType} loadBalancerType + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance */ - EndpointInfo.prototype.sourceIp = ""; + LoadBalancerInfo.prototype.loadBalancerType = 0; /** - * EndpointInfo destinationIp. - * @member {string} destinationIp - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo - * @instance - */ - EndpointInfo.prototype.destinationIp = ""; - - /** - * EndpointInfo protocol. - * @member {string} protocol - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo - * @instance - */ - EndpointInfo.prototype.protocol = ""; - - /** - * EndpointInfo sourcePort. - * @member {number} sourcePort - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo - * @instance - */ - EndpointInfo.prototype.sourcePort = 0; - - /** - * EndpointInfo destinationPort. - * @member {number} destinationPort - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * LoadBalancerInfo healthCheckUri. + * @member {string} healthCheckUri + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance */ - EndpointInfo.prototype.destinationPort = 0; + LoadBalancerInfo.prototype.healthCheckUri = ""; /** - * EndpointInfo sourceNetworkUri. - * @member {string} sourceNetworkUri - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * LoadBalancerInfo backends. + * @member {Array.} backends + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance */ - EndpointInfo.prototype.sourceNetworkUri = ""; + LoadBalancerInfo.prototype.backends = $util.emptyArray; /** - * EndpointInfo destinationNetworkUri. - * @member {string} destinationNetworkUri - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * LoadBalancerInfo backendType. + * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType} backendType + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance */ - EndpointInfo.prototype.destinationNetworkUri = ""; + LoadBalancerInfo.prototype.backendType = 0; /** - * EndpointInfo sourceAgentUri. - * @member {string} sourceAgentUri - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * LoadBalancerInfo backendUri. + * @member {string} backendUri + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance */ - EndpointInfo.prototype.sourceAgentUri = ""; + LoadBalancerInfo.prototype.backendUri = ""; /** - * Creates a new EndpointInfo instance using the specified properties. + * Creates a new LoadBalancerInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo instance + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo instance */ - EndpointInfo.create = function create(properties) { - return new EndpointInfo(properties); + LoadBalancerInfo.create = function create(properties) { + return new LoadBalancerInfo(properties); }; /** - * Encodes the specified EndpointInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.EndpointInfo.verify|verify} messages. + * Encodes the specified LoadBalancerInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo} message EndpointInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo} message LoadBalancerInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EndpointInfo.encode = function encode(message, writer) { + LoadBalancerInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.sourceIp != null && Object.hasOwnProperty.call(message, "sourceIp")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.sourceIp); - if (message.destinationIp != null && Object.hasOwnProperty.call(message, "destinationIp")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.destinationIp); - if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.protocol); - if (message.sourcePort != null && Object.hasOwnProperty.call(message, "sourcePort")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.sourcePort); - if (message.destinationPort != null && Object.hasOwnProperty.call(message, "destinationPort")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.destinationPort); - if (message.sourceNetworkUri != null && Object.hasOwnProperty.call(message, "sourceNetworkUri")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.sourceNetworkUri); - if (message.destinationNetworkUri != null && Object.hasOwnProperty.call(message, "destinationNetworkUri")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.destinationNetworkUri); - if (message.sourceAgentUri != null && Object.hasOwnProperty.call(message, "sourceAgentUri")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.sourceAgentUri); + if (message.loadBalancerType != null && Object.hasOwnProperty.call(message, "loadBalancerType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.loadBalancerType); + if (message.healthCheckUri != null && Object.hasOwnProperty.call(message, "healthCheckUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.healthCheckUri); + if (message.backends != null && message.backends.length) + for (var i = 0; i < message.backends.length; ++i) + $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.encode(message.backends[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.backendType != null && Object.hasOwnProperty.call(message, "backendType")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.backendType); + if (message.backendUri != null && Object.hasOwnProperty.call(message, "backendUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.backendUri); return writer; }; /** - * Encodes the specified EndpointInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.EndpointInfo.verify|verify} messages. + * Encodes the specified LoadBalancerInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo} message EndpointInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerInfo} message LoadBalancerInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EndpointInfo.encodeDelimited = function encodeDelimited(message, writer) { + LoadBalancerInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EndpointInfo message from the specified reader or buffer. + * Decodes a LoadBalancerInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EndpointInfo.decode = function decode(reader, length) { + LoadBalancerInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.EndpointInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.sourceIp = reader.string(); + message.loadBalancerType = reader.int32(); break; } case 2: { - message.destinationIp = reader.string(); + message.healthCheckUri = reader.string(); break; } case 3: { - message.protocol = reader.string(); + if (!(message.backends && message.backends.length)) + message.backends = []; + message.backends.push($root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.decode(reader, reader.uint32())); break; } case 4: { - message.sourcePort = reader.int32(); + message.backendType = reader.int32(); break; } case 5: { - message.destinationPort = reader.int32(); - break; - } - case 6: { - message.sourceNetworkUri = reader.string(); - break; - } - case 7: { - message.destinationNetworkUri = reader.string(); - break; - } - case 8: { - message.sourceAgentUri = reader.string(); + message.backendUri = reader.string(); break; } default: @@ -26873,181 +27303,287 @@ }; /** - * Decodes an EndpointInfo message from the specified reader or buffer, length delimited. + * Decodes a LoadBalancerInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EndpointInfo.decodeDelimited = function decodeDelimited(reader) { + LoadBalancerInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EndpointInfo message. + * Verifies a LoadBalancerInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EndpointInfo.verify = function verify(message) { + LoadBalancerInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) - if (!$util.isString(message.sourceIp)) - return "sourceIp: string expected"; - if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) - if (!$util.isString(message.destinationIp)) - return "destinationIp: string expected"; - if (message.protocol != null && message.hasOwnProperty("protocol")) - if (!$util.isString(message.protocol)) - return "protocol: string expected"; - if (message.sourcePort != null && message.hasOwnProperty("sourcePort")) - if (!$util.isInteger(message.sourcePort)) - return "sourcePort: integer expected"; - if (message.destinationPort != null && message.hasOwnProperty("destinationPort")) - if (!$util.isInteger(message.destinationPort)) - return "destinationPort: integer expected"; - if (message.sourceNetworkUri != null && message.hasOwnProperty("sourceNetworkUri")) - if (!$util.isString(message.sourceNetworkUri)) - return "sourceNetworkUri: string expected"; - if (message.destinationNetworkUri != null && message.hasOwnProperty("destinationNetworkUri")) - if (!$util.isString(message.destinationNetworkUri)) - return "destinationNetworkUri: string expected"; - if (message.sourceAgentUri != null && message.hasOwnProperty("sourceAgentUri")) - if (!$util.isString(message.sourceAgentUri)) - return "sourceAgentUri: string expected"; + if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) + switch (message.loadBalancerType) { + default: + return "loadBalancerType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + break; + } + if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) + if (!$util.isString(message.healthCheckUri)) + return "healthCheckUri: string expected"; + if (message.backends != null && message.hasOwnProperty("backends")) { + if (!Array.isArray(message.backends)) + return "backends: array expected"; + for (var i = 0; i < message.backends.length; ++i) { + var error = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify(message.backends[i]); + if (error) + return "backends." + error; + } + } + if (message.backendType != null && message.hasOwnProperty("backendType")) + switch (message.backendType) { + default: + return "backendType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + break; + } + if (message.backendUri != null && message.hasOwnProperty("backendUri")) + if (!$util.isString(message.backendUri)) + return "backendUri: string expected"; return null; }; /** - * Creates an EndpointInfo message from a plain object. Also converts values to their respective internal types. + * Creates a LoadBalancerInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} LoadBalancerInfo */ - EndpointInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.EndpointInfo) + LoadBalancerInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.EndpointInfo(); - if (object.sourceIp != null) - message.sourceIp = String(object.sourceIp); - if (object.destinationIp != null) - message.destinationIp = String(object.destinationIp); - if (object.protocol != null) - message.protocol = String(object.protocol); - if (object.sourcePort != null) - message.sourcePort = object.sourcePort | 0; - if (object.destinationPort != null) - message.destinationPort = object.destinationPort | 0; - if (object.sourceNetworkUri != null) - message.sourceNetworkUri = String(object.sourceNetworkUri); - if (object.destinationNetworkUri != null) - message.destinationNetworkUri = String(object.destinationNetworkUri); - if (object.sourceAgentUri != null) - message.sourceAgentUri = String(object.sourceAgentUri); - return message; - }; - - /** - * Creates a plain object from an EndpointInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.EndpointInfo} message EndpointInfo + var message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo(); + switch (object.loadBalancerType) { + default: + if (typeof object.loadBalancerType === "number") { + message.loadBalancerType = object.loadBalancerType; + break; + } + break; + case "LOAD_BALANCER_TYPE_UNSPECIFIED": + case 0: + message.loadBalancerType = 0; + break; + case "INTERNAL_TCP_UDP": + case 1: + message.loadBalancerType = 1; + break; + case "NETWORK_TCP_UDP": + case 2: + message.loadBalancerType = 2; + break; + case "HTTP_PROXY": + case 3: + message.loadBalancerType = 3; + break; + case "TCP_PROXY": + case 4: + message.loadBalancerType = 4; + break; + case "SSL_PROXY": + case 5: + message.loadBalancerType = 5; + break; + } + if (object.healthCheckUri != null) + message.healthCheckUri = String(object.healthCheckUri); + if (object.backends) { + if (!Array.isArray(object.backends)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.backends: array expected"); + message.backends = []; + for (var i = 0; i < object.backends.length; ++i) { + if (typeof object.backends[i] !== "object") + throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.backends: object expected"); + message.backends[i] = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.fromObject(object.backends[i]); + } + } + switch (object.backendType) { + default: + if (typeof object.backendType === "number") { + message.backendType = object.backendType; + break; + } + break; + case "BACKEND_TYPE_UNSPECIFIED": + case 0: + message.backendType = 0; + break; + case "BACKEND_SERVICE": + case 1: + message.backendType = 1; + break; + case "TARGET_POOL": + case 2: + message.backendType = 2; + break; + case "TARGET_INSTANCE": + case 3: + message.backendType = 3; + break; + } + if (object.backendUri != null) + message.backendUri = String(object.backendUri); + return message; + }; + + /** + * Creates a plain object from a LoadBalancerInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.LoadBalancerInfo} message LoadBalancerInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EndpointInfo.toObject = function toObject(message, options) { + LoadBalancerInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.backends = []; if (options.defaults) { - object.sourceIp = ""; - object.destinationIp = ""; - object.protocol = ""; - object.sourcePort = 0; - object.destinationPort = 0; - object.sourceNetworkUri = ""; - object.destinationNetworkUri = ""; - object.sourceAgentUri = ""; + object.loadBalancerType = options.enums === String ? "LOAD_BALANCER_TYPE_UNSPECIFIED" : 0; + object.healthCheckUri = ""; + object.backendType = options.enums === String ? "BACKEND_TYPE_UNSPECIFIED" : 0; + object.backendUri = ""; } - if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) - object.sourceIp = message.sourceIp; - if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) - object.destinationIp = message.destinationIp; - if (message.protocol != null && message.hasOwnProperty("protocol")) - object.protocol = message.protocol; - if (message.sourcePort != null && message.hasOwnProperty("sourcePort")) - object.sourcePort = message.sourcePort; - if (message.destinationPort != null && message.hasOwnProperty("destinationPort")) - object.destinationPort = message.destinationPort; - if (message.sourceNetworkUri != null && message.hasOwnProperty("sourceNetworkUri")) - object.sourceNetworkUri = message.sourceNetworkUri; - if (message.destinationNetworkUri != null && message.hasOwnProperty("destinationNetworkUri")) - object.destinationNetworkUri = message.destinationNetworkUri; - if (message.sourceAgentUri != null && message.hasOwnProperty("sourceAgentUri")) - object.sourceAgentUri = message.sourceAgentUri; + if (message.loadBalancerType != null && message.hasOwnProperty("loadBalancerType")) + object.loadBalancerType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType[message.loadBalancerType] === undefined ? message.loadBalancerType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType[message.loadBalancerType] : message.loadBalancerType; + if (message.healthCheckUri != null && message.hasOwnProperty("healthCheckUri")) + object.healthCheckUri = message.healthCheckUri; + if (message.backends && message.backends.length) { + object.backends = []; + for (var j = 0; j < message.backends.length; ++j) + object.backends[j] = $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.toObject(message.backends[j], options); + } + if (message.backendType != null && message.hasOwnProperty("backendType")) + object.backendType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType[message.backendType] === undefined ? message.backendType : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType[message.backendType] : message.backendType; + if (message.backendUri != null && message.hasOwnProperty("backendUri")) + object.backendUri = message.backendUri; return object; }; /** - * Converts this EndpointInfo to JSON. + * Converts this LoadBalancerInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @instance * @returns {Object.} JSON object */ - EndpointInfo.prototype.toJSON = function toJSON() { + LoadBalancerInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EndpointInfo + * Gets the default type url for LoadBalancerInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EndpointInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + LoadBalancerInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.EndpointInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LoadBalancerInfo"; }; - return EndpointInfo; + /** + * LoadBalancerType enum. + * @name google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.LoadBalancerType + * @enum {number} + * @property {number} LOAD_BALANCER_TYPE_UNSPECIFIED=0 LOAD_BALANCER_TYPE_UNSPECIFIED value + * @property {number} INTERNAL_TCP_UDP=1 INTERNAL_TCP_UDP value + * @property {number} NETWORK_TCP_UDP=2 NETWORK_TCP_UDP value + * @property {number} HTTP_PROXY=3 HTTP_PROXY value + * @property {number} TCP_PROXY=4 TCP_PROXY value + * @property {number} SSL_PROXY=5 SSL_PROXY value + */ + LoadBalancerInfo.LoadBalancerType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "LOAD_BALANCER_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "INTERNAL_TCP_UDP"] = 1; + values[valuesById[2] = "NETWORK_TCP_UDP"] = 2; + values[valuesById[3] = "HTTP_PROXY"] = 3; + values[valuesById[4] = "TCP_PROXY"] = 4; + values[valuesById[5] = "SSL_PROXY"] = 5; + return values; + })(); + + /** + * BackendType enum. + * @name google.cloud.networkmanagement.v1beta1.LoadBalancerInfo.BackendType + * @enum {number} + * @property {number} BACKEND_TYPE_UNSPECIFIED=0 BACKEND_TYPE_UNSPECIFIED value + * @property {number} BACKEND_SERVICE=1 BACKEND_SERVICE value + * @property {number} TARGET_POOL=2 TARGET_POOL value + * @property {number} TARGET_INSTANCE=3 TARGET_INSTANCE value + */ + LoadBalancerInfo.BackendType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "BACKEND_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "BACKEND_SERVICE"] = 1; + values[valuesById[2] = "TARGET_POOL"] = 2; + values[valuesById[3] = "TARGET_INSTANCE"] = 3; + return values; + })(); + + return LoadBalancerInfo; })(); - v1beta1.DeliverInfo = (function() { + v1beta1.LoadBalancerBackend = (function() { /** - * Properties of a DeliverInfo. + * Properties of a LoadBalancerBackend. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IDeliverInfo - * @property {google.cloud.networkmanagement.v1beta1.DeliverInfo.Target|null} [target] DeliverInfo target - * @property {string|null} [resourceUri] DeliverInfo resourceUri - * @property {string|null} [ipAddress] DeliverInfo ipAddress + * @interface ILoadBalancerBackend + * @property {string|null} [displayName] LoadBalancerBackend displayName + * @property {string|null} [uri] LoadBalancerBackend uri + * @property {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState|null} [healthCheckFirewallState] LoadBalancerBackend healthCheckFirewallState + * @property {Array.|null} [healthCheckAllowingFirewallRules] LoadBalancerBackend healthCheckAllowingFirewallRules + * @property {Array.|null} [healthCheckBlockingFirewallRules] LoadBalancerBackend healthCheckBlockingFirewallRules */ /** - * Constructs a new DeliverInfo. + * Constructs a new LoadBalancerBackend. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a DeliverInfo. - * @implements IDeliverInfo + * @classdesc Represents a LoadBalancerBackend. + * @implements ILoadBalancerBackend * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend=} [properties] Properties to set */ - function DeliverInfo(properties) { + function LoadBalancerBackend(properties) { + this.healthCheckAllowingFirewallRules = []; + this.healthCheckBlockingFirewallRules = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27055,103 +27591,137 @@ } /** - * DeliverInfo target. - * @member {google.cloud.networkmanagement.v1beta1.DeliverInfo.Target} target - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * LoadBalancerBackend displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @instance */ - DeliverInfo.prototype.target = 0; + LoadBalancerBackend.prototype.displayName = ""; /** - * DeliverInfo resourceUri. - * @member {string} resourceUri - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * LoadBalancerBackend uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @instance */ - DeliverInfo.prototype.resourceUri = ""; + LoadBalancerBackend.prototype.uri = ""; /** - * DeliverInfo ipAddress. - * @member {string} ipAddress - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * LoadBalancerBackend healthCheckFirewallState. + * @member {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState} healthCheckFirewallState + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @instance */ - DeliverInfo.prototype.ipAddress = ""; + LoadBalancerBackend.prototype.healthCheckFirewallState = 0; /** - * Creates a new DeliverInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo instance + * LoadBalancerBackend healthCheckAllowingFirewallRules. + * @member {Array.} healthCheckAllowingFirewallRules + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @instance */ - DeliverInfo.create = function create(properties) { - return new DeliverInfo(properties); - }; + LoadBalancerBackend.prototype.healthCheckAllowingFirewallRules = $util.emptyArray; /** - * Encodes the specified DeliverInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DeliverInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo} message DeliverInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * LoadBalancerBackend healthCheckBlockingFirewallRules. + * @member {Array.} healthCheckBlockingFirewallRules + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @instance */ - DeliverInfo.encode = function encode(message, writer) { + LoadBalancerBackend.prototype.healthCheckBlockingFirewallRules = $util.emptyArray; + + /** + * Creates a new LoadBalancerBackend instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @static + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend instance + */ + LoadBalancerBackend.create = function create(properties) { + return new LoadBalancerBackend(properties); + }; + + /** + * Encodes the specified LoadBalancerBackend message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend + * @static + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend} message LoadBalancerBackend message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LoadBalancerBackend.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.target != null && Object.hasOwnProperty.call(message, "target")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.target); - if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); - if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.ipAddress); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.healthCheckFirewallState != null && Object.hasOwnProperty.call(message, "healthCheckFirewallState")) + writer.uint32(/* id 3, wireType 0 =*/24).int32(message.healthCheckFirewallState); + if (message.healthCheckAllowingFirewallRules != null && message.healthCheckAllowingFirewallRules.length) + for (var i = 0; i < message.healthCheckAllowingFirewallRules.length; ++i) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.healthCheckAllowingFirewallRules[i]); + if (message.healthCheckBlockingFirewallRules != null && message.healthCheckBlockingFirewallRules.length) + for (var i = 0; i < message.healthCheckBlockingFirewallRules.length; ++i) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.healthCheckBlockingFirewallRules[i]); return writer; }; /** - * Encodes the specified DeliverInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DeliverInfo.verify|verify} messages. + * Encodes the specified LoadBalancerBackend message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static - * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo} message DeliverInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.ILoadBalancerBackend} message LoadBalancerBackend message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeliverInfo.encodeDelimited = function encodeDelimited(message, writer) { + LoadBalancerBackend.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeliverInfo message from the specified reader or buffer. + * Decodes a LoadBalancerBackend message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeliverInfo.decode = function decode(reader, length) { + LoadBalancerBackend.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.DeliverInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.target = reader.int32(); + message.displayName = reader.string(); break; } case 2: { - message.resourceUri = reader.string(); + message.uri = reader.string(); break; } case 3: { - message.ipAddress = reader.string(); + message.healthCheckFirewallState = reader.int32(); + break; + } + case 4: { + if (!(message.healthCheckAllowingFirewallRules && message.healthCheckAllowingFirewallRules.length)) + message.healthCheckAllowingFirewallRules = []; + message.healthCheckAllowingFirewallRules.push(reader.string()); + break; + } + case 5: { + if (!(message.healthCheckBlockingFirewallRules && message.healthCheckBlockingFirewallRules.length)) + message.healthCheckBlockingFirewallRules = []; + message.healthCheckBlockingFirewallRules.push(reader.string()); break; } default: @@ -27163,265 +27733,226 @@ }; /** - * Decodes a DeliverInfo message from the specified reader or buffer, length delimited. + * Decodes a LoadBalancerBackend message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeliverInfo.decodeDelimited = function decodeDelimited(reader) { + LoadBalancerBackend.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeliverInfo message. + * Verifies a LoadBalancerBackend message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeliverInfo.verify = function verify(message) { + LoadBalancerBackend.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.target != null && message.hasOwnProperty("target")) - switch (message.target) { + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.healthCheckFirewallState != null && message.hasOwnProperty("healthCheckFirewallState")) + switch (message.healthCheckFirewallState) { default: - return "target: enum value expected"; + return "healthCheckFirewallState: enum value expected"; case 0: case 1: case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - case 10: - case 11: - case 12: - case 13: - case 14: break; } - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - if (!$util.isString(message.resourceUri)) - return "resourceUri: string expected"; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - if (!$util.isString(message.ipAddress)) - return "ipAddress: string expected"; + if (message.healthCheckAllowingFirewallRules != null && message.hasOwnProperty("healthCheckAllowingFirewallRules")) { + if (!Array.isArray(message.healthCheckAllowingFirewallRules)) + return "healthCheckAllowingFirewallRules: array expected"; + for (var i = 0; i < message.healthCheckAllowingFirewallRules.length; ++i) + if (!$util.isString(message.healthCheckAllowingFirewallRules[i])) + return "healthCheckAllowingFirewallRules: string[] expected"; + } + if (message.healthCheckBlockingFirewallRules != null && message.hasOwnProperty("healthCheckBlockingFirewallRules")) { + if (!Array.isArray(message.healthCheckBlockingFirewallRules)) + return "healthCheckBlockingFirewallRules: array expected"; + for (var i = 0; i < message.healthCheckBlockingFirewallRules.length; ++i) + if (!$util.isString(message.healthCheckBlockingFirewallRules[i])) + return "healthCheckBlockingFirewallRules: string[] expected"; + } return null; }; /** - * Creates a DeliverInfo message from a plain object. Also converts values to their respective internal types. + * Creates a LoadBalancerBackend message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + * @returns {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} LoadBalancerBackend */ - DeliverInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.DeliverInfo) + LoadBalancerBackend.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.DeliverInfo(); - switch (object.target) { + var message = new $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + switch (object.healthCheckFirewallState) { default: - if (typeof object.target === "number") { - message.target = object.target; + if (typeof object.healthCheckFirewallState === "number") { + message.healthCheckFirewallState = object.healthCheckFirewallState; break; } break; - case "TARGET_UNSPECIFIED": + case "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED": case 0: - message.target = 0; + message.healthCheckFirewallState = 0; break; - case "INSTANCE": + case "CONFIGURED": case 1: - message.target = 1; + message.healthCheckFirewallState = 1; break; - case "INTERNET": + case "MISCONFIGURED": case 2: - message.target = 2; - break; - case "GOOGLE_API": - case 3: - message.target = 3; - break; - case "GKE_MASTER": - case 4: - message.target = 4; - break; - case "CLOUD_SQL_INSTANCE": - case 5: - message.target = 5; - break; - case "PSC_PUBLISHED_SERVICE": - case 6: - message.target = 6; - break; - case "PSC_GOOGLE_API": - case 7: - message.target = 7; - break; - case "PSC_VPC_SC": - case 8: - message.target = 8; - break; - case "SERVERLESS_NEG": - case 9: - message.target = 9; - break; - case "STORAGE_BUCKET": - case 10: - message.target = 10; - break; - case "PRIVATE_NETWORK": - case 11: - message.target = 11; - break; - case "CLOUD_FUNCTION": - case 12: - message.target = 12; - break; - case "APP_ENGINE_VERSION": - case 13: - message.target = 13; - break; - case "CLOUD_RUN_REVISION": - case 14: - message.target = 14; + message.healthCheckFirewallState = 2; break; } - if (object.resourceUri != null) - message.resourceUri = String(object.resourceUri); - if (object.ipAddress != null) - message.ipAddress = String(object.ipAddress); + if (object.healthCheckAllowingFirewallRules) { + if (!Array.isArray(object.healthCheckAllowingFirewallRules)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.healthCheckAllowingFirewallRules: array expected"); + message.healthCheckAllowingFirewallRules = []; + for (var i = 0; i < object.healthCheckAllowingFirewallRules.length; ++i) + message.healthCheckAllowingFirewallRules[i] = String(object.healthCheckAllowingFirewallRules[i]); + } + if (object.healthCheckBlockingFirewallRules) { + if (!Array.isArray(object.healthCheckBlockingFirewallRules)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.healthCheckBlockingFirewallRules: array expected"); + message.healthCheckBlockingFirewallRules = []; + for (var i = 0; i < object.healthCheckBlockingFirewallRules.length; ++i) + message.healthCheckBlockingFirewallRules[i] = String(object.healthCheckBlockingFirewallRules[i]); + } return message; }; /** - * Creates a plain object from a DeliverInfo message. Also converts values to other types if specified. + * Creates a plain object from a LoadBalancerBackend message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static - * @param {google.cloud.networkmanagement.v1beta1.DeliverInfo} message DeliverInfo + * @param {google.cloud.networkmanagement.v1beta1.LoadBalancerBackend} message LoadBalancerBackend * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeliverInfo.toObject = function toObject(message, options) { + LoadBalancerBackend.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.healthCheckAllowingFirewallRules = []; + object.healthCheckBlockingFirewallRules = []; + } if (options.defaults) { - object.target = options.enums === String ? "TARGET_UNSPECIFIED" : 0; - object.resourceUri = ""; - object.ipAddress = ""; + object.displayName = ""; + object.uri = ""; + object.healthCheckFirewallState = options.enums === String ? "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED" : 0; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.healthCheckFirewallState != null && message.hasOwnProperty("healthCheckFirewallState")) + object.healthCheckFirewallState = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState[message.healthCheckFirewallState] === undefined ? message.healthCheckFirewallState : $root.google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState[message.healthCheckFirewallState] : message.healthCheckFirewallState; + if (message.healthCheckAllowingFirewallRules && message.healthCheckAllowingFirewallRules.length) { + object.healthCheckAllowingFirewallRules = []; + for (var j = 0; j < message.healthCheckAllowingFirewallRules.length; ++j) + object.healthCheckAllowingFirewallRules[j] = message.healthCheckAllowingFirewallRules[j]; + } + if (message.healthCheckBlockingFirewallRules && message.healthCheckBlockingFirewallRules.length) { + object.healthCheckBlockingFirewallRules = []; + for (var j = 0; j < message.healthCheckBlockingFirewallRules.length; ++j) + object.healthCheckBlockingFirewallRules[j] = message.healthCheckBlockingFirewallRules[j]; } - if (message.target != null && message.hasOwnProperty("target")) - object.target = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.Target[message.target] === undefined ? message.target : $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.Target[message.target] : message.target; - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - object.resourceUri = message.resourceUri; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - object.ipAddress = message.ipAddress; return object; }; /** - * Converts this DeliverInfo to JSON. + * Converts this LoadBalancerBackend to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @instance * @returns {Object.} JSON object */ - DeliverInfo.prototype.toJSON = function toJSON() { + LoadBalancerBackend.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeliverInfo + * Gets the default type url for LoadBalancerBackend * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @memberof google.cloud.networkmanagement.v1beta1.LoadBalancerBackend * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeliverInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + LoadBalancerBackend.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.DeliverInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.LoadBalancerBackend"; }; /** - * Target enum. - * @name google.cloud.networkmanagement.v1beta1.DeliverInfo.Target + * HealthCheckFirewallState enum. + * @name google.cloud.networkmanagement.v1beta1.LoadBalancerBackend.HealthCheckFirewallState * @enum {number} - * @property {number} TARGET_UNSPECIFIED=0 TARGET_UNSPECIFIED value - * @property {number} INSTANCE=1 INSTANCE value - * @property {number} INTERNET=2 INTERNET value - * @property {number} GOOGLE_API=3 GOOGLE_API value - * @property {number} GKE_MASTER=4 GKE_MASTER value - * @property {number} CLOUD_SQL_INSTANCE=5 CLOUD_SQL_INSTANCE value - * @property {number} PSC_PUBLISHED_SERVICE=6 PSC_PUBLISHED_SERVICE value - * @property {number} PSC_GOOGLE_API=7 PSC_GOOGLE_API value - * @property {number} PSC_VPC_SC=8 PSC_VPC_SC value - * @property {number} SERVERLESS_NEG=9 SERVERLESS_NEG value - * @property {number} STORAGE_BUCKET=10 STORAGE_BUCKET value - * @property {number} PRIVATE_NETWORK=11 PRIVATE_NETWORK value - * @property {number} CLOUD_FUNCTION=12 CLOUD_FUNCTION value - * @property {number} APP_ENGINE_VERSION=13 APP_ENGINE_VERSION value - * @property {number} CLOUD_RUN_REVISION=14 CLOUD_RUN_REVISION value + * @property {number} HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED=0 HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED value + * @property {number} CONFIGURED=1 CONFIGURED value + * @property {number} MISCONFIGURED=2 MISCONFIGURED value */ - DeliverInfo.Target = (function() { + LoadBalancerBackend.HealthCheckFirewallState = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "TARGET_UNSPECIFIED"] = 0; - values[valuesById[1] = "INSTANCE"] = 1; - values[valuesById[2] = "INTERNET"] = 2; - values[valuesById[3] = "GOOGLE_API"] = 3; - values[valuesById[4] = "GKE_MASTER"] = 4; - values[valuesById[5] = "CLOUD_SQL_INSTANCE"] = 5; - values[valuesById[6] = "PSC_PUBLISHED_SERVICE"] = 6; - values[valuesById[7] = "PSC_GOOGLE_API"] = 7; - values[valuesById[8] = "PSC_VPC_SC"] = 8; - values[valuesById[9] = "SERVERLESS_NEG"] = 9; - values[valuesById[10] = "STORAGE_BUCKET"] = 10; - values[valuesById[11] = "PRIVATE_NETWORK"] = 11; - values[valuesById[12] = "CLOUD_FUNCTION"] = 12; - values[valuesById[13] = "APP_ENGINE_VERSION"] = 13; - values[valuesById[14] = "CLOUD_RUN_REVISION"] = 14; + values[valuesById[0] = "HEALTH_CHECK_FIREWALL_STATE_UNSPECIFIED"] = 0; + values[valuesById[1] = "CONFIGURED"] = 1; + values[valuesById[2] = "MISCONFIGURED"] = 2; return values; })(); - return DeliverInfo; + return LoadBalancerBackend; })(); - v1beta1.ForwardInfo = (function() { + v1beta1.VpnGatewayInfo = (function() { /** - * Properties of a ForwardInfo. + * Properties of a VpnGatewayInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IForwardInfo - * @property {google.cloud.networkmanagement.v1beta1.ForwardInfo.Target|null} [target] ForwardInfo target - * @property {string|null} [resourceUri] ForwardInfo resourceUri - * @property {string|null} [ipAddress] ForwardInfo ipAddress + * @interface IVpnGatewayInfo + * @property {string|null} [displayName] VpnGatewayInfo displayName + * @property {string|null} [uri] VpnGatewayInfo uri + * @property {string|null} [networkUri] VpnGatewayInfo networkUri + * @property {string|null} [ipAddress] VpnGatewayInfo ipAddress + * @property {string|null} [vpnTunnelUri] VpnGatewayInfo vpnTunnelUri + * @property {string|null} [region] VpnGatewayInfo region */ /** - * Constructs a new ForwardInfo. + * Constructs a new VpnGatewayInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a ForwardInfo. - * @implements IForwardInfo + * @classdesc Represents a VpnGatewayInfo. + * @implements IVpnGatewayInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo=} [properties] Properties to set */ - function ForwardInfo(properties) { + function VpnGatewayInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27429,105 +27960,147 @@ } /** - * ForwardInfo target. - * @member {google.cloud.networkmanagement.v1beta1.ForwardInfo.Target} target - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * VpnGatewayInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @instance */ - ForwardInfo.prototype.target = 0; + VpnGatewayInfo.prototype.displayName = ""; /** - * ForwardInfo resourceUri. - * @member {string} resourceUri - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * VpnGatewayInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @instance */ - ForwardInfo.prototype.resourceUri = ""; + VpnGatewayInfo.prototype.uri = ""; /** - * ForwardInfo ipAddress. + * VpnGatewayInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @instance + */ + VpnGatewayInfo.prototype.networkUri = ""; + + /** + * VpnGatewayInfo ipAddress. * @member {string} ipAddress - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @instance */ - ForwardInfo.prototype.ipAddress = ""; + VpnGatewayInfo.prototype.ipAddress = ""; /** - * Creates a new ForwardInfo instance using the specified properties. + * VpnGatewayInfo vpnTunnelUri. + * @member {string} vpnTunnelUri + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @instance + */ + VpnGatewayInfo.prototype.vpnTunnelUri = ""; + + /** + * VpnGatewayInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo + * @instance + */ + VpnGatewayInfo.prototype.region = ""; + + /** + * Creates a new VpnGatewayInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo instance */ - ForwardInfo.create = function create(properties) { - return new ForwardInfo(properties); + VpnGatewayInfo.create = function create(properties) { + return new VpnGatewayInfo(properties); }; /** - * Encodes the specified ForwardInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardInfo.verify|verify} messages. + * Encodes the specified VpnGatewayInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo} message ForwardInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo} message VpnGatewayInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ForwardInfo.encode = function encode(message, writer) { + VpnGatewayInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.target != null && Object.hasOwnProperty.call(message, "target")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.target); - if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.ipAddress); + writer.uint32(/* id 4, wireType 2 =*/34).string(message.ipAddress); + if (message.vpnTunnelUri != null && Object.hasOwnProperty.call(message, "vpnTunnelUri")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.vpnTunnelUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); return writer; }; /** - * Encodes the specified ForwardInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardInfo.verify|verify} messages. + * Encodes the specified VpnGatewayInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnGatewayInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo} message ForwardInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IVpnGatewayInfo} message VpnGatewayInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ForwardInfo.encodeDelimited = function encodeDelimited(message, writer) { + VpnGatewayInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ForwardInfo message from the specified reader or buffer. + * Decodes a VpnGatewayInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ForwardInfo.decode = function decode(reader, length) { + VpnGatewayInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ForwardInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.target = reader.int32(); + message.displayName = reader.string(); break; } case 2: { - message.resourceUri = reader.string(); + message.uri = reader.string(); break; } case 3: { + message.networkUri = reader.string(); + break; + } + case 4: { message.ipAddress = reader.string(); break; } + case 5: { + message.vpnTunnelUri = reader.string(); + break; + } + case 6: { + message.region = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -27537,232 +28110,171 @@ }; /** - * Decodes a ForwardInfo message from the specified reader or buffer, length delimited. + * Decodes a VpnGatewayInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ForwardInfo.decodeDelimited = function decodeDelimited(reader) { + VpnGatewayInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ForwardInfo message. + * Verifies a VpnGatewayInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ForwardInfo.verify = function verify(message) { + VpnGatewayInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.target != null && message.hasOwnProperty("target")) - switch (message.target) { - default: - return "target: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - break; - } - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - if (!$util.isString(message.resourceUri)) - return "resourceUri: string expected"; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - if (!$util.isString(message.ipAddress)) - return "ipAddress: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + if (!$util.isString(message.ipAddress)) + return "ipAddress: string expected"; + if (message.vpnTunnelUri != null && message.hasOwnProperty("vpnTunnelUri")) + if (!$util.isString(message.vpnTunnelUri)) + return "vpnTunnelUri: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; return null; }; /** - * Creates a ForwardInfo message from a plain object. Also converts values to their respective internal types. + * Creates a VpnGatewayInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} VpnGatewayInfo */ - ForwardInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ForwardInfo) + VpnGatewayInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.ForwardInfo(); - switch (object.target) { - default: - if (typeof object.target === "number") { - message.target = object.target; - break; - } - break; - case "TARGET_UNSPECIFIED": - case 0: - message.target = 0; - break; - case "PEERING_VPC": - case 1: - message.target = 1; - break; - case "VPN_GATEWAY": - case 2: - message.target = 2; - break; - case "INTERCONNECT": - case 3: - message.target = 3; - break; - case "GKE_MASTER": - case 4: - message.target = 4; - break; - case "IMPORTED_CUSTOM_ROUTE_NEXT_HOP": - case 5: - message.target = 5; - break; - case "CLOUD_SQL_INSTANCE": - case 6: - message.target = 6; - break; - case "ANOTHER_PROJECT": - case 7: - message.target = 7; - break; - case "NCC_HUB": - case 8: - message.target = 8; - break; - case "ROUTER_APPLIANCE": - case 9: - message.target = 9; - break; - } - if (object.resourceUri != null) - message.resourceUri = String(object.resourceUri); + var message = new $root.google.cloud.networkmanagement.v1beta1.VpnGatewayInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); if (object.ipAddress != null) message.ipAddress = String(object.ipAddress); + if (object.vpnTunnelUri != null) + message.vpnTunnelUri = String(object.vpnTunnelUri); + if (object.region != null) + message.region = String(object.region); return message; }; /** - * Creates a plain object from a ForwardInfo message. Also converts values to other types if specified. + * Creates a plain object from a VpnGatewayInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ForwardInfo} message ForwardInfo + * @param {google.cloud.networkmanagement.v1beta1.VpnGatewayInfo} message VpnGatewayInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ForwardInfo.toObject = function toObject(message, options) { + VpnGatewayInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.target = options.enums === String ? "TARGET_UNSPECIFIED" : 0; - object.resourceUri = ""; + object.displayName = ""; + object.uri = ""; + object.networkUri = ""; object.ipAddress = ""; + object.vpnTunnelUri = ""; + object.region = ""; } - if (message.target != null && message.hasOwnProperty("target")) - object.target = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.Target[message.target] === undefined ? message.target : $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.Target[message.target] : message.target; - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - object.resourceUri = message.resourceUri; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) object.ipAddress = message.ipAddress; + if (message.vpnTunnelUri != null && message.hasOwnProperty("vpnTunnelUri")) + object.vpnTunnelUri = message.vpnTunnelUri; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; /** - * Converts this ForwardInfo to JSON. + * Converts this VpnGatewayInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @instance * @returns {Object.} JSON object */ - ForwardInfo.prototype.toJSON = function toJSON() { + VpnGatewayInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ForwardInfo + * Gets the default type url for VpnGatewayInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnGatewayInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ForwardInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + VpnGatewayInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ForwardInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.VpnGatewayInfo"; }; - /** - * Target enum. - * @name google.cloud.networkmanagement.v1beta1.ForwardInfo.Target - * @enum {number} - * @property {number} TARGET_UNSPECIFIED=0 TARGET_UNSPECIFIED value - * @property {number} PEERING_VPC=1 PEERING_VPC value - * @property {number} VPN_GATEWAY=2 VPN_GATEWAY value - * @property {number} INTERCONNECT=3 INTERCONNECT value - * @property {number} GKE_MASTER=4 GKE_MASTER value - * @property {number} IMPORTED_CUSTOM_ROUTE_NEXT_HOP=5 IMPORTED_CUSTOM_ROUTE_NEXT_HOP value - * @property {number} CLOUD_SQL_INSTANCE=6 CLOUD_SQL_INSTANCE value - * @property {number} ANOTHER_PROJECT=7 ANOTHER_PROJECT value - * @property {number} NCC_HUB=8 NCC_HUB value - * @property {number} ROUTER_APPLIANCE=9 ROUTER_APPLIANCE value - */ - ForwardInfo.Target = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "TARGET_UNSPECIFIED"] = 0; - values[valuesById[1] = "PEERING_VPC"] = 1; - values[valuesById[2] = "VPN_GATEWAY"] = 2; - values[valuesById[3] = "INTERCONNECT"] = 3; - values[valuesById[4] = "GKE_MASTER"] = 4; - values[valuesById[5] = "IMPORTED_CUSTOM_ROUTE_NEXT_HOP"] = 5; - values[valuesById[6] = "CLOUD_SQL_INSTANCE"] = 6; - values[valuesById[7] = "ANOTHER_PROJECT"] = 7; - values[valuesById[8] = "NCC_HUB"] = 8; - values[valuesById[9] = "ROUTER_APPLIANCE"] = 9; - return values; - })(); - - return ForwardInfo; + return VpnGatewayInfo; })(); - v1beta1.AbortInfo = (function() { + v1beta1.VpnTunnelInfo = (function() { /** - * Properties of an AbortInfo. + * Properties of a VpnTunnelInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IAbortInfo - * @property {google.cloud.networkmanagement.v1beta1.AbortInfo.Cause|null} [cause] AbortInfo cause - * @property {string|null} [resourceUri] AbortInfo resourceUri - * @property {string|null} [ipAddress] AbortInfo ipAddress - * @property {Array.|null} [projectsMissingPermission] AbortInfo projectsMissingPermission + * @interface IVpnTunnelInfo + * @property {string|null} [displayName] VpnTunnelInfo displayName + * @property {string|null} [uri] VpnTunnelInfo uri + * @property {string|null} [sourceGateway] VpnTunnelInfo sourceGateway + * @property {string|null} [remoteGateway] VpnTunnelInfo remoteGateway + * @property {string|null} [remoteGatewayIp] VpnTunnelInfo remoteGatewayIp + * @property {string|null} [sourceGatewayIp] VpnTunnelInfo sourceGatewayIp + * @property {string|null} [networkUri] VpnTunnelInfo networkUri + * @property {string|null} [region] VpnTunnelInfo region + * @property {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType|null} [routingType] VpnTunnelInfo routingType */ /** - * Constructs a new AbortInfo. + * Constructs a new VpnTunnelInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents an AbortInfo. - * @implements IAbortInfo + * @classdesc Represents a VpnTunnelInfo. + * @implements IVpnTunnelInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo=} [properties] Properties to set */ - function AbortInfo(properties) { - this.projectsMissingPermission = []; + function VpnTunnelInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27770,120 +28282,187 @@ } /** - * AbortInfo cause. - * @member {google.cloud.networkmanagement.v1beta1.AbortInfo.Cause} cause - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * VpnTunnelInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @instance */ - AbortInfo.prototype.cause = 0; + VpnTunnelInfo.prototype.displayName = ""; /** - * AbortInfo resourceUri. - * @member {string} resourceUri - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * VpnTunnelInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @instance */ - AbortInfo.prototype.resourceUri = ""; + VpnTunnelInfo.prototype.uri = ""; /** - * AbortInfo ipAddress. - * @member {string} ipAddress - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * VpnTunnelInfo sourceGateway. + * @member {string} sourceGateway + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @instance */ - AbortInfo.prototype.ipAddress = ""; + VpnTunnelInfo.prototype.sourceGateway = ""; /** - * AbortInfo projectsMissingPermission. - * @member {Array.} projectsMissingPermission - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * VpnTunnelInfo remoteGateway. + * @member {string} remoteGateway + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @instance */ - AbortInfo.prototype.projectsMissingPermission = $util.emptyArray; + VpnTunnelInfo.prototype.remoteGateway = ""; /** - * Creates a new AbortInfo instance using the specified properties. - * @function create - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo instance + * VpnTunnelInfo remoteGatewayIp. + * @member {string} remoteGatewayIp + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @instance */ - AbortInfo.create = function create(properties) { - return new AbortInfo(properties); - }; + VpnTunnelInfo.prototype.remoteGatewayIp = ""; /** - * Encodes the specified AbortInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.AbortInfo.verify|verify} messages. - * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo - * @static - * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo} message AbortInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * VpnTunnelInfo sourceGatewayIp. + * @member {string} sourceGatewayIp + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @instance */ - AbortInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.cause != null && Object.hasOwnProperty.call(message, "cause")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.cause); - if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); - if (message.projectsMissingPermission != null && message.projectsMissingPermission.length) - for (var i = 0; i < message.projectsMissingPermission.length; ++i) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.projectsMissingPermission[i]); - if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.ipAddress); + VpnTunnelInfo.prototype.sourceGatewayIp = ""; + + /** + * VpnTunnelInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @instance + */ + VpnTunnelInfo.prototype.networkUri = ""; + + /** + * VpnTunnelInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @instance + */ + VpnTunnelInfo.prototype.region = ""; + + /** + * VpnTunnelInfo routingType. + * @member {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType} routingType + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @instance + */ + VpnTunnelInfo.prototype.routingType = 0; + + /** + * Creates a new VpnTunnelInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo instance + */ + VpnTunnelInfo.create = function create(properties) { + return new VpnTunnelInfo(properties); + }; + + /** + * Encodes the specified VpnTunnelInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo} message VpnTunnelInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + VpnTunnelInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.sourceGateway != null && Object.hasOwnProperty.call(message, "sourceGateway")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.sourceGateway); + if (message.remoteGateway != null && Object.hasOwnProperty.call(message, "remoteGateway")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.remoteGateway); + if (message.remoteGatewayIp != null && Object.hasOwnProperty.call(message, "remoteGatewayIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.remoteGatewayIp); + if (message.sourceGatewayIp != null && Object.hasOwnProperty.call(message, "sourceGatewayIp")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.sourceGatewayIp); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.networkUri); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.region); + if (message.routingType != null && Object.hasOwnProperty.call(message, "routingType")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.routingType); return writer; }; /** - * Encodes the specified AbortInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.AbortInfo.verify|verify} messages. + * Encodes the specified VpnTunnelInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo} message AbortInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IVpnTunnelInfo} message VpnTunnelInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - AbortInfo.encodeDelimited = function encodeDelimited(message, writer) { + VpnTunnelInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an AbortInfo message from the specified reader or buffer. + * Decodes a VpnTunnelInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - AbortInfo.decode = function decode(reader, length) { + VpnTunnelInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.AbortInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.cause = reader.int32(); + message.displayName = reader.string(); break; } case 2: { - message.resourceUri = reader.string(); + message.uri = reader.string(); + break; + } + case 3: { + message.sourceGateway = reader.string(); break; } case 4: { - message.ipAddress = reader.string(); + message.remoteGateway = reader.string(); break; } - case 3: { - if (!(message.projectsMissingPermission && message.projectsMissingPermission.length)) - message.projectsMissingPermission = []; - message.projectsMissingPermission.push(reader.string()); + case 5: { + message.remoteGatewayIp = reader.string(); + break; + } + case 6: { + message.sourceGatewayIp = reader.string(); + break; + } + case 7: { + message.networkUri = reader.string(); + break; + } + case 8: { + message.region = reader.string(); + break; + } + case 9: { + message.routingType = reader.int32(); break; } default: @@ -27895,407 +28474,241 @@ }; /** - * Decodes an AbortInfo message from the specified reader or buffer, length delimited. + * Decodes a VpnTunnelInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - AbortInfo.decodeDelimited = function decodeDelimited(reader) { + VpnTunnelInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an AbortInfo message. + * Verifies a VpnTunnelInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - AbortInfo.verify = function verify(message) { + VpnTunnelInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.cause != null && message.hasOwnProperty("cause")) - switch (message.cause) { + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.sourceGateway != null && message.hasOwnProperty("sourceGateway")) + if (!$util.isString(message.sourceGateway)) + return "sourceGateway: string expected"; + if (message.remoteGateway != null && message.hasOwnProperty("remoteGateway")) + if (!$util.isString(message.remoteGateway)) + return "remoteGateway: string expected"; + if (message.remoteGatewayIp != null && message.hasOwnProperty("remoteGatewayIp")) + if (!$util.isString(message.remoteGatewayIp)) + return "remoteGatewayIp: string expected"; + if (message.sourceGatewayIp != null && message.hasOwnProperty("sourceGatewayIp")) + if (!$util.isString(message.sourceGatewayIp)) + return "sourceGatewayIp: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; + if (message.routingType != null && message.hasOwnProperty("routingType")) + switch (message.routingType) { default: - return "cause: enum value expected"; + return "routingType: enum value expected"; case 0: case 1: - case 3: - case 7: - case 8: - case 11: - case 12: - case 13: - case 14: case 2: - case 23: - case 4: - case 28: - case 29: - case 5: - case 6: - case 9: - case 10: - case 15: - case 16: - case 17: - case 18: - case 24: - case 25: - case 26: - case 27: - case 19: - case 20: - case 21: - case 22: - case 30: - case 31: + case 3: break; } - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - if (!$util.isString(message.resourceUri)) - return "resourceUri: string expected"; - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - if (!$util.isString(message.ipAddress)) - return "ipAddress: string expected"; - if (message.projectsMissingPermission != null && message.hasOwnProperty("projectsMissingPermission")) { - if (!Array.isArray(message.projectsMissingPermission)) - return "projectsMissingPermission: array expected"; - for (var i = 0; i < message.projectsMissingPermission.length; ++i) - if (!$util.isString(message.projectsMissingPermission[i])) - return "projectsMissingPermission: string[] expected"; - } return null; }; /** - * Creates an AbortInfo message from a plain object. Also converts values to their respective internal types. + * Creates a VpnTunnelInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + * @returns {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} VpnTunnelInfo */ - AbortInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.AbortInfo) + VpnTunnelInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.AbortInfo(); - switch (object.cause) { + var message = new $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.sourceGateway != null) + message.sourceGateway = String(object.sourceGateway); + if (object.remoteGateway != null) + message.remoteGateway = String(object.remoteGateway); + if (object.remoteGatewayIp != null) + message.remoteGatewayIp = String(object.remoteGatewayIp); + if (object.sourceGatewayIp != null) + message.sourceGatewayIp = String(object.sourceGatewayIp); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.region != null) + message.region = String(object.region); + switch (object.routingType) { default: - if (typeof object.cause === "number") { - message.cause = object.cause; + if (typeof object.routingType === "number") { + message.routingType = object.routingType; break; } break; - case "CAUSE_UNSPECIFIED": + case "ROUTING_TYPE_UNSPECIFIED": case 0: - message.cause = 0; + message.routingType = 0; break; - case "UNKNOWN_NETWORK": + case "ROUTE_BASED": case 1: - message.cause = 1; + message.routingType = 1; break; - case "UNKNOWN_PROJECT": - case 3: - message.cause = 3; - break; - case "NO_EXTERNAL_IP": - case 7: - message.cause = 7; - break; - case "UNINTENDED_DESTINATION": - case 8: - message.cause = 8; - break; - case "SOURCE_ENDPOINT_NOT_FOUND": - case 11: - message.cause = 11; - break; - case "MISMATCHED_SOURCE_NETWORK": - case 12: - message.cause = 12; - break; - case "DESTINATION_ENDPOINT_NOT_FOUND": - case 13: - message.cause = 13; - break; - case "MISMATCHED_DESTINATION_NETWORK": - case 14: - message.cause = 14; - break; - case "UNKNOWN_IP": + case "POLICY_BASED": case 2: - message.cause = 2; - break; - case "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK": - case 23: - message.cause = 23; - break; - case "PERMISSION_DENIED": - case 4: - message.cause = 4; - break; - case "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS": - case 28: - message.cause = 28; - break; - case "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS": - case 29: - message.cause = 29; - break; - case "NO_SOURCE_LOCATION": - case 5: - message.cause = 5; - break; - case "INVALID_ARGUMENT": - case 6: - message.cause = 6; - break; - case "TRACE_TOO_LONG": - case 9: - message.cause = 9; - break; - case "INTERNAL_ERROR": - case 10: - message.cause = 10; - break; - case "UNSUPPORTED": - case 15: - message.cause = 15; - break; - case "MISMATCHED_IP_VERSION": - case 16: - message.cause = 16; - break; - case "GKE_KONNECTIVITY_PROXY_UNSUPPORTED": - case 17: - message.cause = 17; - break; - case "RESOURCE_CONFIG_NOT_FOUND": - case 18: - message.cause = 18; - break; - case "VM_INSTANCE_CONFIG_NOT_FOUND": - case 24: - message.cause = 24; - break; - case "NETWORK_CONFIG_NOT_FOUND": - case 25: - message.cause = 25; - break; - case "FIREWALL_CONFIG_NOT_FOUND": - case 26: - message.cause = 26; - break; - case "ROUTE_CONFIG_NOT_FOUND": - case 27: - message.cause = 27; - break; - case "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT": - case 19: - message.cause = 19; - break; - case "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED": - case 20: - message.cause = 20; - break; - case "SOURCE_FORWARDING_RULE_UNSUPPORTED": - case 21: - message.cause = 21; - break; - case "NON_ROUTABLE_IP_ADDRESS": - case 22: - message.cause = 22; - break; - case "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT": - case 30: - message.cause = 30; + message.routingType = 2; break; - case "UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG": - case 31: - message.cause = 31; + case "DYNAMIC": + case 3: + message.routingType = 3; break; } - if (object.resourceUri != null) - message.resourceUri = String(object.resourceUri); - if (object.ipAddress != null) - message.ipAddress = String(object.ipAddress); - if (object.projectsMissingPermission) { - if (!Array.isArray(object.projectsMissingPermission)) - throw TypeError(".google.cloud.networkmanagement.v1beta1.AbortInfo.projectsMissingPermission: array expected"); - message.projectsMissingPermission = []; - for (var i = 0; i < object.projectsMissingPermission.length; ++i) - message.projectsMissingPermission[i] = String(object.projectsMissingPermission[i]); - } return message; }; /** - * Creates a plain object from an AbortInfo message. Also converts values to other types if specified. + * Creates a plain object from a VpnTunnelInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.AbortInfo} message AbortInfo + * @param {google.cloud.networkmanagement.v1beta1.VpnTunnelInfo} message VpnTunnelInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - AbortInfo.toObject = function toObject(message, options) { + VpnTunnelInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.projectsMissingPermission = []; if (options.defaults) { - object.cause = options.enums === String ? "CAUSE_UNSPECIFIED" : 0; - object.resourceUri = ""; - object.ipAddress = ""; - } - if (message.cause != null && message.hasOwnProperty("cause")) - object.cause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.AbortInfo.Cause[message.cause] === undefined ? message.cause : $root.google.cloud.networkmanagement.v1beta1.AbortInfo.Cause[message.cause] : message.cause; - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - object.resourceUri = message.resourceUri; - if (message.projectsMissingPermission && message.projectsMissingPermission.length) { - object.projectsMissingPermission = []; - for (var j = 0; j < message.projectsMissingPermission.length; ++j) - object.projectsMissingPermission[j] = message.projectsMissingPermission[j]; + object.displayName = ""; + object.uri = ""; + object.sourceGateway = ""; + object.remoteGateway = ""; + object.remoteGatewayIp = ""; + object.sourceGatewayIp = ""; + object.networkUri = ""; + object.region = ""; + object.routingType = options.enums === String ? "ROUTING_TYPE_UNSPECIFIED" : 0; } - if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) - object.ipAddress = message.ipAddress; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.sourceGateway != null && message.hasOwnProperty("sourceGateway")) + object.sourceGateway = message.sourceGateway; + if (message.remoteGateway != null && message.hasOwnProperty("remoteGateway")) + object.remoteGateway = message.remoteGateway; + if (message.remoteGatewayIp != null && message.hasOwnProperty("remoteGatewayIp")) + object.remoteGatewayIp = message.remoteGatewayIp; + if (message.sourceGatewayIp != null && message.hasOwnProperty("sourceGatewayIp")) + object.sourceGatewayIp = message.sourceGatewayIp; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; + if (message.routingType != null && message.hasOwnProperty("routingType")) + object.routingType = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType[message.routingType] === undefined ? message.routingType : $root.google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType[message.routingType] : message.routingType; return object; }; /** - * Converts this AbortInfo to JSON. + * Converts this VpnTunnelInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @instance * @returns {Object.} JSON object */ - AbortInfo.prototype.toJSON = function toJSON() { + VpnTunnelInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for AbortInfo + * Gets the default type url for VpnTunnelInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @memberof google.cloud.networkmanagement.v1beta1.VpnTunnelInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - AbortInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + VpnTunnelInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.AbortInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.VpnTunnelInfo"; }; /** - * Cause enum. - * @name google.cloud.networkmanagement.v1beta1.AbortInfo.Cause + * RoutingType enum. + * @name google.cloud.networkmanagement.v1beta1.VpnTunnelInfo.RoutingType * @enum {number} - * @property {number} CAUSE_UNSPECIFIED=0 CAUSE_UNSPECIFIED value - * @property {number} UNKNOWN_NETWORK=1 UNKNOWN_NETWORK value - * @property {number} UNKNOWN_PROJECT=3 UNKNOWN_PROJECT value - * @property {number} NO_EXTERNAL_IP=7 NO_EXTERNAL_IP value - * @property {number} UNINTENDED_DESTINATION=8 UNINTENDED_DESTINATION value - * @property {number} SOURCE_ENDPOINT_NOT_FOUND=11 SOURCE_ENDPOINT_NOT_FOUND value - * @property {number} MISMATCHED_SOURCE_NETWORK=12 MISMATCHED_SOURCE_NETWORK value - * @property {number} DESTINATION_ENDPOINT_NOT_FOUND=13 DESTINATION_ENDPOINT_NOT_FOUND value - * @property {number} MISMATCHED_DESTINATION_NETWORK=14 MISMATCHED_DESTINATION_NETWORK value - * @property {number} UNKNOWN_IP=2 UNKNOWN_IP value - * @property {number} SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK=23 SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK value - * @property {number} PERMISSION_DENIED=4 PERMISSION_DENIED value - * @property {number} PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS=28 PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS value - * @property {number} PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS=29 PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS value - * @property {number} NO_SOURCE_LOCATION=5 NO_SOURCE_LOCATION value - * @property {number} INVALID_ARGUMENT=6 INVALID_ARGUMENT value - * @property {number} TRACE_TOO_LONG=9 TRACE_TOO_LONG value - * @property {number} INTERNAL_ERROR=10 INTERNAL_ERROR value - * @property {number} UNSUPPORTED=15 UNSUPPORTED value - * @property {number} MISMATCHED_IP_VERSION=16 MISMATCHED_IP_VERSION value - * @property {number} GKE_KONNECTIVITY_PROXY_UNSUPPORTED=17 GKE_KONNECTIVITY_PROXY_UNSUPPORTED value - * @property {number} RESOURCE_CONFIG_NOT_FOUND=18 RESOURCE_CONFIG_NOT_FOUND value - * @property {number} VM_INSTANCE_CONFIG_NOT_FOUND=24 VM_INSTANCE_CONFIG_NOT_FOUND value - * @property {number} NETWORK_CONFIG_NOT_FOUND=25 NETWORK_CONFIG_NOT_FOUND value - * @property {number} FIREWALL_CONFIG_NOT_FOUND=26 FIREWALL_CONFIG_NOT_FOUND value - * @property {number} ROUTE_CONFIG_NOT_FOUND=27 ROUTE_CONFIG_NOT_FOUND value - * @property {number} GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT=19 GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT value - * @property {number} SOURCE_PSC_CLOUD_SQL_UNSUPPORTED=20 SOURCE_PSC_CLOUD_SQL_UNSUPPORTED value - * @property {number} SOURCE_FORWARDING_RULE_UNSUPPORTED=21 SOURCE_FORWARDING_RULE_UNSUPPORTED value - * @property {number} NON_ROUTABLE_IP_ADDRESS=22 NON_ROUTABLE_IP_ADDRESS value - * @property {number} UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT=30 UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT value - * @property {number} UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG=31 UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG value + * @property {number} ROUTING_TYPE_UNSPECIFIED=0 ROUTING_TYPE_UNSPECIFIED value + * @property {number} ROUTE_BASED=1 ROUTE_BASED value + * @property {number} POLICY_BASED=2 POLICY_BASED value + * @property {number} DYNAMIC=3 DYNAMIC value */ - AbortInfo.Cause = (function() { + VpnTunnelInfo.RoutingType = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "CAUSE_UNSPECIFIED"] = 0; - values[valuesById[1] = "UNKNOWN_NETWORK"] = 1; - values[valuesById[3] = "UNKNOWN_PROJECT"] = 3; - values[valuesById[7] = "NO_EXTERNAL_IP"] = 7; - values[valuesById[8] = "UNINTENDED_DESTINATION"] = 8; - values[valuesById[11] = "SOURCE_ENDPOINT_NOT_FOUND"] = 11; - values[valuesById[12] = "MISMATCHED_SOURCE_NETWORK"] = 12; - values[valuesById[13] = "DESTINATION_ENDPOINT_NOT_FOUND"] = 13; - values[valuesById[14] = "MISMATCHED_DESTINATION_NETWORK"] = 14; - values[valuesById[2] = "UNKNOWN_IP"] = 2; - values[valuesById[23] = "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK"] = 23; - values[valuesById[4] = "PERMISSION_DENIED"] = 4; - values[valuesById[28] = "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS"] = 28; - values[valuesById[29] = "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS"] = 29; - values[valuesById[5] = "NO_SOURCE_LOCATION"] = 5; - values[valuesById[6] = "INVALID_ARGUMENT"] = 6; - values[valuesById[9] = "TRACE_TOO_LONG"] = 9; - values[valuesById[10] = "INTERNAL_ERROR"] = 10; - values[valuesById[15] = "UNSUPPORTED"] = 15; - values[valuesById[16] = "MISMATCHED_IP_VERSION"] = 16; - values[valuesById[17] = "GKE_KONNECTIVITY_PROXY_UNSUPPORTED"] = 17; - values[valuesById[18] = "RESOURCE_CONFIG_NOT_FOUND"] = 18; - values[valuesById[24] = "VM_INSTANCE_CONFIG_NOT_FOUND"] = 24; - values[valuesById[25] = "NETWORK_CONFIG_NOT_FOUND"] = 25; - values[valuesById[26] = "FIREWALL_CONFIG_NOT_FOUND"] = 26; - values[valuesById[27] = "ROUTE_CONFIG_NOT_FOUND"] = 27; - values[valuesById[19] = "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT"] = 19; - values[valuesById[20] = "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED"] = 20; - values[valuesById[21] = "SOURCE_FORWARDING_RULE_UNSUPPORTED"] = 21; - values[valuesById[22] = "NON_ROUTABLE_IP_ADDRESS"] = 22; - values[valuesById[30] = "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT"] = 30; - values[valuesById[31] = "UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG"] = 31; + values[valuesById[0] = "ROUTING_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "ROUTE_BASED"] = 1; + values[valuesById[2] = "POLICY_BASED"] = 2; + values[valuesById[3] = "DYNAMIC"] = 3; return values; })(); - return AbortInfo; + return VpnTunnelInfo; })(); - v1beta1.DropInfo = (function() { + v1beta1.EndpointInfo = (function() { /** - * Properties of a DropInfo. + * Properties of an EndpointInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IDropInfo - * @property {google.cloud.networkmanagement.v1beta1.DropInfo.Cause|null} [cause] DropInfo cause - * @property {string|null} [resourceUri] DropInfo resourceUri - * @property {string|null} [sourceIp] DropInfo sourceIp - * @property {string|null} [destinationIp] DropInfo destinationIp - * @property {string|null} [region] DropInfo region + * @interface IEndpointInfo + * @property {string|null} [sourceIp] EndpointInfo sourceIp + * @property {string|null} [destinationIp] EndpointInfo destinationIp + * @property {string|null} [protocol] EndpointInfo protocol + * @property {number|null} [sourcePort] EndpointInfo sourcePort + * @property {number|null} [destinationPort] EndpointInfo destinationPort + * @property {string|null} [sourceNetworkUri] EndpointInfo sourceNetworkUri + * @property {string|null} [destinationNetworkUri] EndpointInfo destinationNetworkUri + * @property {string|null} [sourceAgentUri] EndpointInfo sourceAgentUri */ /** - * Constructs a new DropInfo. + * Constructs a new EndpointInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a DropInfo. - * @implements IDropInfo + * @classdesc Represents an EndpointInfo. + * @implements IEndpointInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IDropInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo=} [properties] Properties to set */ - function DropInfo(properties) { + function EndpointInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -28303,131 +28716,173 @@ } /** - * DropInfo cause. - * @member {google.cloud.networkmanagement.v1beta1.DropInfo.Cause} cause - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * EndpointInfo sourceIp. + * @member {string} sourceIp + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @instance */ - DropInfo.prototype.cause = 0; + EndpointInfo.prototype.sourceIp = ""; /** - * DropInfo resourceUri. - * @member {string} resourceUri - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * EndpointInfo destinationIp. + * @member {string} destinationIp + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @instance */ - DropInfo.prototype.resourceUri = ""; + EndpointInfo.prototype.destinationIp = ""; /** - * DropInfo sourceIp. - * @member {string} sourceIp - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * EndpointInfo protocol. + * @member {string} protocol + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @instance */ - DropInfo.prototype.sourceIp = ""; + EndpointInfo.prototype.protocol = ""; /** - * DropInfo destinationIp. - * @member {string} destinationIp - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * EndpointInfo sourcePort. + * @member {number} sourcePort + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @instance */ - DropInfo.prototype.destinationIp = ""; + EndpointInfo.prototype.sourcePort = 0; /** - * DropInfo region. - * @member {string} region - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * EndpointInfo destinationPort. + * @member {number} destinationPort + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @instance */ - DropInfo.prototype.region = ""; + EndpointInfo.prototype.destinationPort = 0; /** - * Creates a new DropInfo instance using the specified properties. + * EndpointInfo sourceNetworkUri. + * @member {string} sourceNetworkUri + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @instance + */ + EndpointInfo.prototype.sourceNetworkUri = ""; + + /** + * EndpointInfo destinationNetworkUri. + * @member {string} destinationNetworkUri + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @instance + */ + EndpointInfo.prototype.destinationNetworkUri = ""; + + /** + * EndpointInfo sourceAgentUri. + * @member {string} sourceAgentUri + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @instance + */ + EndpointInfo.prototype.sourceAgentUri = ""; + + /** + * Creates a new EndpointInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IDropInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo instance */ - DropInfo.create = function create(properties) { - return new DropInfo(properties); + EndpointInfo.create = function create(properties) { + return new EndpointInfo(properties); }; /** - * Encodes the specified DropInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DropInfo.verify|verify} messages. + * Encodes the specified EndpointInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.EndpointInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IDropInfo} message DropInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo} message EndpointInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DropInfo.encode = function encode(message, writer) { + EndpointInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.cause != null && Object.hasOwnProperty.call(message, "cause")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.cause); - if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); if (message.sourceIp != null && Object.hasOwnProperty.call(message, "sourceIp")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.sourceIp); + writer.uint32(/* id 1, wireType 2 =*/10).string(message.sourceIp); if (message.destinationIp != null && Object.hasOwnProperty.call(message, "destinationIp")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.destinationIp); - if (message.region != null && Object.hasOwnProperty.call(message, "region")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.region); + writer.uint32(/* id 2, wireType 2 =*/18).string(message.destinationIp); + if (message.protocol != null && Object.hasOwnProperty.call(message, "protocol")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.protocol); + if (message.sourcePort != null && Object.hasOwnProperty.call(message, "sourcePort")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.sourcePort); + if (message.destinationPort != null && Object.hasOwnProperty.call(message, "destinationPort")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.destinationPort); + if (message.sourceNetworkUri != null && Object.hasOwnProperty.call(message, "sourceNetworkUri")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.sourceNetworkUri); + if (message.destinationNetworkUri != null && Object.hasOwnProperty.call(message, "destinationNetworkUri")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.destinationNetworkUri); + if (message.sourceAgentUri != null && Object.hasOwnProperty.call(message, "sourceAgentUri")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.sourceAgentUri); return writer; }; /** - * Encodes the specified DropInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DropInfo.verify|verify} messages. + * Encodes the specified EndpointInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.EndpointInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IDropInfo} message DropInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IEndpointInfo} message EndpointInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DropInfo.encodeDelimited = function encodeDelimited(message, writer) { + EndpointInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DropInfo message from the specified reader or buffer. + * Decodes an EndpointInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DropInfo.decode = function decode(reader, length) { + EndpointInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.DropInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.EndpointInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.cause = reader.int32(); + message.sourceIp = reader.string(); break; } case 2: { - message.resourceUri = reader.string(); + message.destinationIp = reader.string(); break; } case 3: { - message.sourceIp = reader.string(); + message.protocol = reader.string(); break; } case 4: { - message.destinationIp = reader.string(); + message.sourcePort = reader.int32(); break; } case 5: { - message.region = reader.string(); + message.destinationPort = reader.int32(); + break; + } + case 6: { + message.sourceNetworkUri = reader.string(); + break; + } + case 7: { + message.destinationNetworkUri = reader.string(); + break; + } + case 8: { + message.sourceAgentUri = reader.string(); break; } default: @@ -28439,326 +28894,2030 @@ }; /** - * Decodes a DropInfo message from the specified reader or buffer, length delimited. + * Decodes an EndpointInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DropInfo.decodeDelimited = function decodeDelimited(reader) { + EndpointInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DropInfo message. + * Verifies an EndpointInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DropInfo.verify = function verify(message) { + EndpointInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.cause != null && message.hasOwnProperty("cause")) - switch (message.cause) { - default: - return "cause: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 42: - case 43: - case 49: - case 50: - case 51: - case 52: - case 53: - case 44: - case 45: - case 46: - case 7: - case 8: - case 47: - case 9: - case 10: - case 11: - case 12: - case 13: - case 14: - case 27: - case 28: - case 15: - case 16: - case 17: - case 18: - case 19: - case 20: - case 38: - case 36: - case 21: - case 30: - case 31: - case 32: - case 33: - case 34: - case 35: - case 22: - case 23: - case 24: - case 25: - case 26: - case 41: - case 48: - case 54: - case 58: - case 57: - case 55: - case 56: - case 29: - case 37: - case 39: - case 40: - case 59: - break; - } - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - if (!$util.isString(message.resourceUri)) - return "resourceUri: string expected"; if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) if (!$util.isString(message.sourceIp)) return "sourceIp: string expected"; if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) if (!$util.isString(message.destinationIp)) return "destinationIp: string expected"; - if (message.region != null && message.hasOwnProperty("region")) - if (!$util.isString(message.region)) - return "region: string expected"; + if (message.protocol != null && message.hasOwnProperty("protocol")) + if (!$util.isString(message.protocol)) + return "protocol: string expected"; + if (message.sourcePort != null && message.hasOwnProperty("sourcePort")) + if (!$util.isInteger(message.sourcePort)) + return "sourcePort: integer expected"; + if (message.destinationPort != null && message.hasOwnProperty("destinationPort")) + if (!$util.isInteger(message.destinationPort)) + return "destinationPort: integer expected"; + if (message.sourceNetworkUri != null && message.hasOwnProperty("sourceNetworkUri")) + if (!$util.isString(message.sourceNetworkUri)) + return "sourceNetworkUri: string expected"; + if (message.destinationNetworkUri != null && message.hasOwnProperty("destinationNetworkUri")) + if (!$util.isString(message.destinationNetworkUri)) + return "destinationNetworkUri: string expected"; + if (message.sourceAgentUri != null && message.hasOwnProperty("sourceAgentUri")) + if (!$util.isString(message.sourceAgentUri)) + return "sourceAgentUri: string expected"; return null; }; /** - * Creates a DropInfo message from a plain object. Also converts values to their respective internal types. + * Creates an EndpointInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + * @returns {google.cloud.networkmanagement.v1beta1.EndpointInfo} EndpointInfo */ - DropInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.DropInfo) + EndpointInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.EndpointInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.DropInfo(); - switch (object.cause) { - default: - if (typeof object.cause === "number") { - message.cause = object.cause; - break; - } - break; - case "CAUSE_UNSPECIFIED": - case 0: - message.cause = 0; - break; - case "UNKNOWN_EXTERNAL_ADDRESS": - case 1: - message.cause = 1; - break; - case "FOREIGN_IP_DISALLOWED": - case 2: - message.cause = 2; - break; - case "FIREWALL_RULE": - case 3: - message.cause = 3; - break; - case "NO_ROUTE": - case 4: - message.cause = 4; - break; - case "ROUTE_BLACKHOLE": - case 5: - message.cause = 5; - break; - case "ROUTE_WRONG_NETWORK": - case 6: - message.cause = 6; - break; - case "ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED": - case 42: - message.cause = 42; - break; - case "ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND": - case 43: - message.cause = 43; - break; - case "ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK": - case 49: - message.cause = 49; - break; - case "ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP": - case 50: - message.cause = 50; - break; - case "ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH": - case 51: - message.cause = 51; - break; - case "ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED": - case 52: - message.cause = 52; - break; - case "ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID": - case 53: - message.cause = 53; - break; - case "NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS": - case 44: - message.cause = 44; - break; - case "VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH": - case 45: - message.cause = 45; - break; - case "VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH": - case 46: - message.cause = 46; - break; - case "PRIVATE_TRAFFIC_TO_INTERNET": - case 7: - message.cause = 7; - break; - case "PRIVATE_GOOGLE_ACCESS_DISALLOWED": - case 8: - message.cause = 8; - break; - case "PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED": - case 47: - message.cause = 47; - break; - case "NO_EXTERNAL_ADDRESS": - case 9: - message.cause = 9; - break; - case "UNKNOWN_INTERNAL_ADDRESS": - case 10: - message.cause = 10; - break; - case "FORWARDING_RULE_MISMATCH": - case 11: - message.cause = 11; - break; - case "FORWARDING_RULE_NO_INSTANCES": - case 12: - message.cause = 12; - break; - case "FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK": - case 13: - message.cause = 13; - break; - case "INSTANCE_NOT_RUNNING": - case 14: - message.cause = 14; - break; - case "GKE_CLUSTER_NOT_RUNNING": - case 27: - message.cause = 27; - break; - case "CLOUD_SQL_INSTANCE_NOT_RUNNING": - case 28: - message.cause = 28; - break; - case "TRAFFIC_TYPE_BLOCKED": - case 15: - message.cause = 15; - break; - case "GKE_MASTER_UNAUTHORIZED_ACCESS": - case 16: - message.cause = 16; - break; - case "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS": - case 17: - message.cause = 17; - break; - case "DROPPED_INSIDE_GKE_SERVICE": - case 18: - message.cause = 18; - break; - case "DROPPED_INSIDE_CLOUD_SQL_SERVICE": - case 19: - message.cause = 19; - break; - case "GOOGLE_MANAGED_SERVICE_NO_PEERING": - case 20: - message.cause = 20; - break; - case "GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT": - case 38: - message.cause = 38; - break; - case "GKE_PSC_ENDPOINT_MISSING": - case 36: - message.cause = 36; - break; - case "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS": - case 21: - message.cause = 21; - break; - case "GKE_CONTROL_PLANE_REGION_MISMATCH": - case 30: - message.cause = 30; - break; - case "PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION": - case 31: - message.cause = 31; - break; - case "GKE_CONTROL_PLANE_NO_ROUTE": - case 32: - message.cause = 32; - break; - case "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC": - case 33: - message.cause = 33; - break; - case "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION": - case 34: - message.cause = 34; - break; - case "CLOUD_SQL_INSTANCE_NO_ROUTE": - case 35: - message.cause = 35; - break; - case "CLOUD_FUNCTION_NOT_ACTIVE": - case 22: - message.cause = 22; - break; - case "VPC_CONNECTOR_NOT_SET": - case 23: - message.cause = 23; - break; - case "VPC_CONNECTOR_NOT_RUNNING": - case 24: - message.cause = 24; - break; - case "FORWARDING_RULE_REGION_MISMATCH": - case 25: - message.cause = 25; - break; - case "PSC_CONNECTION_NOT_ACCEPTED": - case 26: - message.cause = 26; - break; - case "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK": - case 41: + var message = new $root.google.cloud.networkmanagement.v1beta1.EndpointInfo(); + if (object.sourceIp != null) + message.sourceIp = String(object.sourceIp); + if (object.destinationIp != null) + message.destinationIp = String(object.destinationIp); + if (object.protocol != null) + message.protocol = String(object.protocol); + if (object.sourcePort != null) + message.sourcePort = object.sourcePort | 0; + if (object.destinationPort != null) + message.destinationPort = object.destinationPort | 0; + if (object.sourceNetworkUri != null) + message.sourceNetworkUri = String(object.sourceNetworkUri); + if (object.destinationNetworkUri != null) + message.destinationNetworkUri = String(object.destinationNetworkUri); + if (object.sourceAgentUri != null) + message.sourceAgentUri = String(object.sourceAgentUri); + return message; + }; + + /** + * Creates a plain object from an EndpointInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.EndpointInfo} message EndpointInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EndpointInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.sourceIp = ""; + object.destinationIp = ""; + object.protocol = ""; + object.sourcePort = 0; + object.destinationPort = 0; + object.sourceNetworkUri = ""; + object.destinationNetworkUri = ""; + object.sourceAgentUri = ""; + } + if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) + object.sourceIp = message.sourceIp; + if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) + object.destinationIp = message.destinationIp; + if (message.protocol != null && message.hasOwnProperty("protocol")) + object.protocol = message.protocol; + if (message.sourcePort != null && message.hasOwnProperty("sourcePort")) + object.sourcePort = message.sourcePort; + if (message.destinationPort != null && message.hasOwnProperty("destinationPort")) + object.destinationPort = message.destinationPort; + if (message.sourceNetworkUri != null && message.hasOwnProperty("sourceNetworkUri")) + object.sourceNetworkUri = message.sourceNetworkUri; + if (message.destinationNetworkUri != null && message.hasOwnProperty("destinationNetworkUri")) + object.destinationNetworkUri = message.destinationNetworkUri; + if (message.sourceAgentUri != null && message.hasOwnProperty("sourceAgentUri")) + object.sourceAgentUri = message.sourceAgentUri; + return object; + }; + + /** + * Converts this EndpointInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @instance + * @returns {Object.} JSON object + */ + EndpointInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EndpointInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.EndpointInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EndpointInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.EndpointInfo"; + }; + + return EndpointInfo; + })(); + + v1beta1.DeliverInfo = (function() { + + /** + * Properties of a DeliverInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IDeliverInfo + * @property {google.cloud.networkmanagement.v1beta1.DeliverInfo.Target|null} [target] DeliverInfo target + * @property {string|null} [resourceUri] DeliverInfo resourceUri + * @property {string|null} [ipAddress] DeliverInfo ipAddress + * @property {string|null} [storageBucket] DeliverInfo storageBucket + * @property {string|null} [pscGoogleApiTarget] DeliverInfo pscGoogleApiTarget + */ + + /** + * Constructs a new DeliverInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a DeliverInfo. + * @implements IDeliverInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo=} [properties] Properties to set + */ + function DeliverInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * DeliverInfo target. + * @member {google.cloud.networkmanagement.v1beta1.DeliverInfo.Target} target + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.target = 0; + + /** + * DeliverInfo resourceUri. + * @member {string} resourceUri + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.resourceUri = ""; + + /** + * DeliverInfo ipAddress. + * @member {string} ipAddress + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.ipAddress = ""; + + /** + * DeliverInfo storageBucket. + * @member {string} storageBucket + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.storageBucket = ""; + + /** + * DeliverInfo pscGoogleApiTarget. + * @member {string} pscGoogleApiTarget + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + */ + DeliverInfo.prototype.pscGoogleApiTarget = ""; + + /** + * Creates a new DeliverInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo instance + */ + DeliverInfo.create = function create(properties) { + return new DeliverInfo(properties); + }; + + /** + * Encodes the specified DeliverInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DeliverInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo} message DeliverInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeliverInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.target != null && Object.hasOwnProperty.call(message, "target")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.target); + if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); + if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.ipAddress); + if (message.storageBucket != null && Object.hasOwnProperty.call(message, "storageBucket")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.storageBucket); + if (message.pscGoogleApiTarget != null && Object.hasOwnProperty.call(message, "pscGoogleApiTarget")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.pscGoogleApiTarget); + return writer; + }; + + /** + * Encodes the specified DeliverInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DeliverInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDeliverInfo} message DeliverInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeliverInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a DeliverInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeliverInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.DeliverInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.target = reader.int32(); + break; + } + case 2: { + message.resourceUri = reader.string(); + break; + } + case 3: { + message.ipAddress = reader.string(); + break; + } + case 4: { + message.storageBucket = reader.string(); + break; + } + case 5: { + message.pscGoogleApiTarget = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a DeliverInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeliverInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a DeliverInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DeliverInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.target != null && message.hasOwnProperty("target")) + switch (message.target) { + default: + return "target: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + case 9: + case 10: + case 11: + case 12: + case 13: + case 14: + case 15: + case 16: + case 17: + break; + } + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + if (!$util.isString(message.resourceUri)) + return "resourceUri: string expected"; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + if (!$util.isString(message.ipAddress)) + return "ipAddress: string expected"; + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) + if (!$util.isString(message.storageBucket)) + return "storageBucket: string expected"; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + if (!$util.isString(message.pscGoogleApiTarget)) + return "pscGoogleApiTarget: string expected"; + return null; + }; + + /** + * Creates a DeliverInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.DeliverInfo} DeliverInfo + */ + DeliverInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.DeliverInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.DeliverInfo(); + switch (object.target) { + default: + if (typeof object.target === "number") { + message.target = object.target; + break; + } + break; + case "TARGET_UNSPECIFIED": + case 0: + message.target = 0; + break; + case "INSTANCE": + case 1: + message.target = 1; + break; + case "INTERNET": + case 2: + message.target = 2; + break; + case "GOOGLE_API": + case 3: + message.target = 3; + break; + case "GKE_MASTER": + case 4: + message.target = 4; + break; + case "CLOUD_SQL_INSTANCE": + case 5: + message.target = 5; + break; + case "PSC_PUBLISHED_SERVICE": + case 6: + message.target = 6; + break; + case "PSC_GOOGLE_API": + case 7: + message.target = 7; + break; + case "PSC_VPC_SC": + case 8: + message.target = 8; + break; + case "SERVERLESS_NEG": + case 9: + message.target = 9; + break; + case "STORAGE_BUCKET": + case 10: + message.target = 10; + break; + case "PRIVATE_NETWORK": + case 11: + message.target = 11; + break; + case "CLOUD_FUNCTION": + case 12: + message.target = 12; + break; + case "APP_ENGINE_VERSION": + case 13: + message.target = 13; + break; + case "CLOUD_RUN_REVISION": + case 14: + message.target = 14; + break; + case "GOOGLE_MANAGED_SERVICE": + case 15: + message.target = 15; + break; + case "REDIS_INSTANCE": + case 16: + message.target = 16; + break; + case "REDIS_CLUSTER": + case 17: + message.target = 17; + break; + } + if (object.resourceUri != null) + message.resourceUri = String(object.resourceUri); + if (object.ipAddress != null) + message.ipAddress = String(object.ipAddress); + if (object.storageBucket != null) + message.storageBucket = String(object.storageBucket); + if (object.pscGoogleApiTarget != null) + message.pscGoogleApiTarget = String(object.pscGoogleApiTarget); + return message; + }; + + /** + * Creates a plain object from a DeliverInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.DeliverInfo} message DeliverInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DeliverInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.target = options.enums === String ? "TARGET_UNSPECIFIED" : 0; + object.resourceUri = ""; + object.ipAddress = ""; + object.storageBucket = ""; + object.pscGoogleApiTarget = ""; + } + if (message.target != null && message.hasOwnProperty("target")) + object.target = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.Target[message.target] === undefined ? message.target : $root.google.cloud.networkmanagement.v1beta1.DeliverInfo.Target[message.target] : message.target; + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + object.resourceUri = message.resourceUri; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + object.ipAddress = message.ipAddress; + if (message.storageBucket != null && message.hasOwnProperty("storageBucket")) + object.storageBucket = message.storageBucket; + if (message.pscGoogleApiTarget != null && message.hasOwnProperty("pscGoogleApiTarget")) + object.pscGoogleApiTarget = message.pscGoogleApiTarget; + return object; + }; + + /** + * Converts this DeliverInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @instance + * @returns {Object.} JSON object + */ + DeliverInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for DeliverInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.DeliverInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DeliverInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.DeliverInfo"; + }; + + /** + * Target enum. + * @name google.cloud.networkmanagement.v1beta1.DeliverInfo.Target + * @enum {number} + * @property {number} TARGET_UNSPECIFIED=0 TARGET_UNSPECIFIED value + * @property {number} INSTANCE=1 INSTANCE value + * @property {number} INTERNET=2 INTERNET value + * @property {number} GOOGLE_API=3 GOOGLE_API value + * @property {number} GKE_MASTER=4 GKE_MASTER value + * @property {number} CLOUD_SQL_INSTANCE=5 CLOUD_SQL_INSTANCE value + * @property {number} PSC_PUBLISHED_SERVICE=6 PSC_PUBLISHED_SERVICE value + * @property {number} PSC_GOOGLE_API=7 PSC_GOOGLE_API value + * @property {number} PSC_VPC_SC=8 PSC_VPC_SC value + * @property {number} SERVERLESS_NEG=9 SERVERLESS_NEG value + * @property {number} STORAGE_BUCKET=10 STORAGE_BUCKET value + * @property {number} PRIVATE_NETWORK=11 PRIVATE_NETWORK value + * @property {number} CLOUD_FUNCTION=12 CLOUD_FUNCTION value + * @property {number} APP_ENGINE_VERSION=13 APP_ENGINE_VERSION value + * @property {number} CLOUD_RUN_REVISION=14 CLOUD_RUN_REVISION value + * @property {number} GOOGLE_MANAGED_SERVICE=15 GOOGLE_MANAGED_SERVICE value + * @property {number} REDIS_INSTANCE=16 REDIS_INSTANCE value + * @property {number} REDIS_CLUSTER=17 REDIS_CLUSTER value + */ + DeliverInfo.Target = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "TARGET_UNSPECIFIED"] = 0; + values[valuesById[1] = "INSTANCE"] = 1; + values[valuesById[2] = "INTERNET"] = 2; + values[valuesById[3] = "GOOGLE_API"] = 3; + values[valuesById[4] = "GKE_MASTER"] = 4; + values[valuesById[5] = "CLOUD_SQL_INSTANCE"] = 5; + values[valuesById[6] = "PSC_PUBLISHED_SERVICE"] = 6; + values[valuesById[7] = "PSC_GOOGLE_API"] = 7; + values[valuesById[8] = "PSC_VPC_SC"] = 8; + values[valuesById[9] = "SERVERLESS_NEG"] = 9; + values[valuesById[10] = "STORAGE_BUCKET"] = 10; + values[valuesById[11] = "PRIVATE_NETWORK"] = 11; + values[valuesById[12] = "CLOUD_FUNCTION"] = 12; + values[valuesById[13] = "APP_ENGINE_VERSION"] = 13; + values[valuesById[14] = "CLOUD_RUN_REVISION"] = 14; + values[valuesById[15] = "GOOGLE_MANAGED_SERVICE"] = 15; + values[valuesById[16] = "REDIS_INSTANCE"] = 16; + values[valuesById[17] = "REDIS_CLUSTER"] = 17; + return values; + })(); + + return DeliverInfo; + })(); + + v1beta1.ForwardInfo = (function() { + + /** + * Properties of a ForwardInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IForwardInfo + * @property {google.cloud.networkmanagement.v1beta1.ForwardInfo.Target|null} [target] ForwardInfo target + * @property {string|null} [resourceUri] ForwardInfo resourceUri + * @property {string|null} [ipAddress] ForwardInfo ipAddress + */ + + /** + * Constructs a new ForwardInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a ForwardInfo. + * @implements IForwardInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo=} [properties] Properties to set + */ + function ForwardInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ForwardInfo target. + * @member {google.cloud.networkmanagement.v1beta1.ForwardInfo.Target} target + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @instance + */ + ForwardInfo.prototype.target = 0; + + /** + * ForwardInfo resourceUri. + * @member {string} resourceUri + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @instance + */ + ForwardInfo.prototype.resourceUri = ""; + + /** + * ForwardInfo ipAddress. + * @member {string} ipAddress + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @instance + */ + ForwardInfo.prototype.ipAddress = ""; + + /** + * Creates a new ForwardInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo instance + */ + ForwardInfo.create = function create(properties) { + return new ForwardInfo(properties); + }; + + /** + * Encodes the specified ForwardInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo} message ForwardInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ForwardInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.target != null && Object.hasOwnProperty.call(message, "target")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.target); + if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); + if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.ipAddress); + return writer; + }; + + /** + * Encodes the specified ForwardInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ForwardInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IForwardInfo} message ForwardInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ForwardInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ForwardInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ForwardInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ForwardInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.target = reader.int32(); + break; + } + case 2: { + message.resourceUri = reader.string(); + break; + } + case 3: { + message.ipAddress = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ForwardInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ForwardInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ForwardInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ForwardInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.target != null && message.hasOwnProperty("target")) + switch (message.target) { + default: + return "target: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + case 9: + break; + } + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + if (!$util.isString(message.resourceUri)) + return "resourceUri: string expected"; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + if (!$util.isString(message.ipAddress)) + return "ipAddress: string expected"; + return null; + }; + + /** + * Creates a ForwardInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.ForwardInfo} ForwardInfo + */ + ForwardInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ForwardInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.ForwardInfo(); + switch (object.target) { + default: + if (typeof object.target === "number") { + message.target = object.target; + break; + } + break; + case "TARGET_UNSPECIFIED": + case 0: + message.target = 0; + break; + case "PEERING_VPC": + case 1: + message.target = 1; + break; + case "VPN_GATEWAY": + case 2: + message.target = 2; + break; + case "INTERCONNECT": + case 3: + message.target = 3; + break; + case "GKE_MASTER": + case 4: + message.target = 4; + break; + case "IMPORTED_CUSTOM_ROUTE_NEXT_HOP": + case 5: + message.target = 5; + break; + case "CLOUD_SQL_INSTANCE": + case 6: + message.target = 6; + break; + case "ANOTHER_PROJECT": + case 7: + message.target = 7; + break; + case "NCC_HUB": + case 8: + message.target = 8; + break; + case "ROUTER_APPLIANCE": + case 9: + message.target = 9; + break; + } + if (object.resourceUri != null) + message.resourceUri = String(object.resourceUri); + if (object.ipAddress != null) + message.ipAddress = String(object.ipAddress); + return message; + }; + + /** + * Creates a plain object from a ForwardInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.ForwardInfo} message ForwardInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ForwardInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.target = options.enums === String ? "TARGET_UNSPECIFIED" : 0; + object.resourceUri = ""; + object.ipAddress = ""; + } + if (message.target != null && message.hasOwnProperty("target")) + object.target = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.Target[message.target] === undefined ? message.target : $root.google.cloud.networkmanagement.v1beta1.ForwardInfo.Target[message.target] : message.target; + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + object.resourceUri = message.resourceUri; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + object.ipAddress = message.ipAddress; + return object; + }; + + /** + * Converts this ForwardInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @instance + * @returns {Object.} JSON object + */ + ForwardInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ForwardInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.ForwardInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ForwardInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ForwardInfo"; + }; + + /** + * Target enum. + * @name google.cloud.networkmanagement.v1beta1.ForwardInfo.Target + * @enum {number} + * @property {number} TARGET_UNSPECIFIED=0 TARGET_UNSPECIFIED value + * @property {number} PEERING_VPC=1 PEERING_VPC value + * @property {number} VPN_GATEWAY=2 VPN_GATEWAY value + * @property {number} INTERCONNECT=3 INTERCONNECT value + * @property {number} GKE_MASTER=4 GKE_MASTER value + * @property {number} IMPORTED_CUSTOM_ROUTE_NEXT_HOP=5 IMPORTED_CUSTOM_ROUTE_NEXT_HOP value + * @property {number} CLOUD_SQL_INSTANCE=6 CLOUD_SQL_INSTANCE value + * @property {number} ANOTHER_PROJECT=7 ANOTHER_PROJECT value + * @property {number} NCC_HUB=8 NCC_HUB value + * @property {number} ROUTER_APPLIANCE=9 ROUTER_APPLIANCE value + */ + ForwardInfo.Target = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "TARGET_UNSPECIFIED"] = 0; + values[valuesById[1] = "PEERING_VPC"] = 1; + values[valuesById[2] = "VPN_GATEWAY"] = 2; + values[valuesById[3] = "INTERCONNECT"] = 3; + values[valuesById[4] = "GKE_MASTER"] = 4; + values[valuesById[5] = "IMPORTED_CUSTOM_ROUTE_NEXT_HOP"] = 5; + values[valuesById[6] = "CLOUD_SQL_INSTANCE"] = 6; + values[valuesById[7] = "ANOTHER_PROJECT"] = 7; + values[valuesById[8] = "NCC_HUB"] = 8; + values[valuesById[9] = "ROUTER_APPLIANCE"] = 9; + return values; + })(); + + return ForwardInfo; + })(); + + v1beta1.AbortInfo = (function() { + + /** + * Properties of an AbortInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IAbortInfo + * @property {google.cloud.networkmanagement.v1beta1.AbortInfo.Cause|null} [cause] AbortInfo cause + * @property {string|null} [resourceUri] AbortInfo resourceUri + * @property {string|null} [ipAddress] AbortInfo ipAddress + * @property {Array.|null} [projectsMissingPermission] AbortInfo projectsMissingPermission + */ + + /** + * Constructs a new AbortInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents an AbortInfo. + * @implements IAbortInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo=} [properties] Properties to set + */ + function AbortInfo(properties) { + this.projectsMissingPermission = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * AbortInfo cause. + * @member {google.cloud.networkmanagement.v1beta1.AbortInfo.Cause} cause + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @instance + */ + AbortInfo.prototype.cause = 0; + + /** + * AbortInfo resourceUri. + * @member {string} resourceUri + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @instance + */ + AbortInfo.prototype.resourceUri = ""; + + /** + * AbortInfo ipAddress. + * @member {string} ipAddress + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @instance + */ + AbortInfo.prototype.ipAddress = ""; + + /** + * AbortInfo projectsMissingPermission. + * @member {Array.} projectsMissingPermission + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @instance + */ + AbortInfo.prototype.projectsMissingPermission = $util.emptyArray; + + /** + * Creates a new AbortInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo instance + */ + AbortInfo.create = function create(properties) { + return new AbortInfo(properties); + }; + + /** + * Encodes the specified AbortInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.AbortInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo} message AbortInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AbortInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.cause != null && Object.hasOwnProperty.call(message, "cause")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.cause); + if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); + if (message.projectsMissingPermission != null && message.projectsMissingPermission.length) + for (var i = 0; i < message.projectsMissingPermission.length; ++i) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.projectsMissingPermission[i]); + if (message.ipAddress != null && Object.hasOwnProperty.call(message, "ipAddress")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.ipAddress); + return writer; + }; + + /** + * Encodes the specified AbortInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.AbortInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IAbortInfo} message AbortInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AbortInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an AbortInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AbortInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.AbortInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.cause = reader.int32(); + break; + } + case 2: { + message.resourceUri = reader.string(); + break; + } + case 4: { + message.ipAddress = reader.string(); + break; + } + case 3: { + if (!(message.projectsMissingPermission && message.projectsMissingPermission.length)) + message.projectsMissingPermission = []; + message.projectsMissingPermission.push(reader.string()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an AbortInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AbortInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an AbortInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + AbortInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.cause != null && message.hasOwnProperty("cause")) + switch (message.cause) { + default: + return "cause: enum value expected"; + case 0: + case 1: + case 3: + case 7: + case 8: + case 11: + case 12: + case 13: + case 14: + case 2: + case 32: + case 23: + case 4: + case 28: + case 29: + case 36: + case 5: + case 6: + case 9: + case 10: + case 15: + case 16: + case 17: + case 18: + case 24: + case 25: + case 26: + case 27: + case 19: + case 20: + case 34: + case 35: + case 21: + case 22: + case 30: + case 31: + break; + } + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + if (!$util.isString(message.resourceUri)) + return "resourceUri: string expected"; + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + if (!$util.isString(message.ipAddress)) + return "ipAddress: string expected"; + if (message.projectsMissingPermission != null && message.hasOwnProperty("projectsMissingPermission")) { + if (!Array.isArray(message.projectsMissingPermission)) + return "projectsMissingPermission: array expected"; + for (var i = 0; i < message.projectsMissingPermission.length; ++i) + if (!$util.isString(message.projectsMissingPermission[i])) + return "projectsMissingPermission: string[] expected"; + } + return null; + }; + + /** + * Creates an AbortInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.AbortInfo} AbortInfo + */ + AbortInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.AbortInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.AbortInfo(); + switch (object.cause) { + default: + if (typeof object.cause === "number") { + message.cause = object.cause; + break; + } + break; + case "CAUSE_UNSPECIFIED": + case 0: + message.cause = 0; + break; + case "UNKNOWN_NETWORK": + case 1: + message.cause = 1; + break; + case "UNKNOWN_PROJECT": + case 3: + message.cause = 3; + break; + case "NO_EXTERNAL_IP": + case 7: + message.cause = 7; + break; + case "UNINTENDED_DESTINATION": + case 8: + message.cause = 8; + break; + case "SOURCE_ENDPOINT_NOT_FOUND": + case 11: + message.cause = 11; + break; + case "MISMATCHED_SOURCE_NETWORK": + case 12: + message.cause = 12; + break; + case "DESTINATION_ENDPOINT_NOT_FOUND": + case 13: + message.cause = 13; + break; + case "MISMATCHED_DESTINATION_NETWORK": + case 14: + message.cause = 14; + break; + case "UNKNOWN_IP": + case 2: + message.cause = 2; + break; + case "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP": + case 32: + message.cause = 32; + break; + case "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK": + case 23: + message.cause = 23; + break; + case "PERMISSION_DENIED": + case 4: + message.cause = 4; + break; + case "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS": + case 28: + message.cause = 28; + break; + case "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS": + case 29: + message.cause = 29; + break; + case "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS": + case 36: + message.cause = 36; + break; + case "NO_SOURCE_LOCATION": + case 5: + message.cause = 5; + break; + case "INVALID_ARGUMENT": + case 6: + message.cause = 6; + break; + case "TRACE_TOO_LONG": + case 9: + message.cause = 9; + break; + case "INTERNAL_ERROR": + case 10: + message.cause = 10; + break; + case "UNSUPPORTED": + case 15: + message.cause = 15; + break; + case "MISMATCHED_IP_VERSION": + case 16: + message.cause = 16; + break; + case "GKE_KONNECTIVITY_PROXY_UNSUPPORTED": + case 17: + message.cause = 17; + break; + case "RESOURCE_CONFIG_NOT_FOUND": + case 18: + message.cause = 18; + break; + case "VM_INSTANCE_CONFIG_NOT_FOUND": + case 24: + message.cause = 24; + break; + case "NETWORK_CONFIG_NOT_FOUND": + case 25: + message.cause = 25; + break; + case "FIREWALL_CONFIG_NOT_FOUND": + case 26: + message.cause = 26; + break; + case "ROUTE_CONFIG_NOT_FOUND": + case 27: + message.cause = 27; + break; + case "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT": + case 19: + message.cause = 19; + break; + case "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED": + case 20: + message.cause = 20; + break; + case "SOURCE_REDIS_CLUSTER_UNSUPPORTED": + case 34: + message.cause = 34; + break; + case "SOURCE_REDIS_INSTANCE_UNSUPPORTED": + case 35: + message.cause = 35; + break; + case "SOURCE_FORWARDING_RULE_UNSUPPORTED": + case 21: + message.cause = 21; + break; + case "NON_ROUTABLE_IP_ADDRESS": + case 22: + message.cause = 22; + break; + case "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT": + case 30: + message.cause = 30; + break; + case "UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG": + case 31: + message.cause = 31; + break; + } + if (object.resourceUri != null) + message.resourceUri = String(object.resourceUri); + if (object.ipAddress != null) + message.ipAddress = String(object.ipAddress); + if (object.projectsMissingPermission) { + if (!Array.isArray(object.projectsMissingPermission)) + throw TypeError(".google.cloud.networkmanagement.v1beta1.AbortInfo.projectsMissingPermission: array expected"); + message.projectsMissingPermission = []; + for (var i = 0; i < object.projectsMissingPermission.length; ++i) + message.projectsMissingPermission[i] = String(object.projectsMissingPermission[i]); + } + return message; + }; + + /** + * Creates a plain object from an AbortInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.AbortInfo} message AbortInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + AbortInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.projectsMissingPermission = []; + if (options.defaults) { + object.cause = options.enums === String ? "CAUSE_UNSPECIFIED" : 0; + object.resourceUri = ""; + object.ipAddress = ""; + } + if (message.cause != null && message.hasOwnProperty("cause")) + object.cause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.AbortInfo.Cause[message.cause] === undefined ? message.cause : $root.google.cloud.networkmanagement.v1beta1.AbortInfo.Cause[message.cause] : message.cause; + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + object.resourceUri = message.resourceUri; + if (message.projectsMissingPermission && message.projectsMissingPermission.length) { + object.projectsMissingPermission = []; + for (var j = 0; j < message.projectsMissingPermission.length; ++j) + object.projectsMissingPermission[j] = message.projectsMissingPermission[j]; + } + if (message.ipAddress != null && message.hasOwnProperty("ipAddress")) + object.ipAddress = message.ipAddress; + return object; + }; + + /** + * Converts this AbortInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @instance + * @returns {Object.} JSON object + */ + AbortInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for AbortInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.AbortInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + AbortInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.AbortInfo"; + }; + + /** + * Cause enum. + * @name google.cloud.networkmanagement.v1beta1.AbortInfo.Cause + * @enum {number} + * @property {number} CAUSE_UNSPECIFIED=0 CAUSE_UNSPECIFIED value + * @property {number} UNKNOWN_NETWORK=1 UNKNOWN_NETWORK value + * @property {number} UNKNOWN_PROJECT=3 UNKNOWN_PROJECT value + * @property {number} NO_EXTERNAL_IP=7 NO_EXTERNAL_IP value + * @property {number} UNINTENDED_DESTINATION=8 UNINTENDED_DESTINATION value + * @property {number} SOURCE_ENDPOINT_NOT_FOUND=11 SOURCE_ENDPOINT_NOT_FOUND value + * @property {number} MISMATCHED_SOURCE_NETWORK=12 MISMATCHED_SOURCE_NETWORK value + * @property {number} DESTINATION_ENDPOINT_NOT_FOUND=13 DESTINATION_ENDPOINT_NOT_FOUND value + * @property {number} MISMATCHED_DESTINATION_NETWORK=14 MISMATCHED_DESTINATION_NETWORK value + * @property {number} UNKNOWN_IP=2 UNKNOWN_IP value + * @property {number} GOOGLE_MANAGED_SERVICE_UNKNOWN_IP=32 GOOGLE_MANAGED_SERVICE_UNKNOWN_IP value + * @property {number} SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK=23 SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK value + * @property {number} PERMISSION_DENIED=4 PERMISSION_DENIED value + * @property {number} PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS=28 PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS value + * @property {number} PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS=29 PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS value + * @property {number} PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS=36 PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS value + * @property {number} NO_SOURCE_LOCATION=5 NO_SOURCE_LOCATION value + * @property {number} INVALID_ARGUMENT=6 INVALID_ARGUMENT value + * @property {number} TRACE_TOO_LONG=9 TRACE_TOO_LONG value + * @property {number} INTERNAL_ERROR=10 INTERNAL_ERROR value + * @property {number} UNSUPPORTED=15 UNSUPPORTED value + * @property {number} MISMATCHED_IP_VERSION=16 MISMATCHED_IP_VERSION value + * @property {number} GKE_KONNECTIVITY_PROXY_UNSUPPORTED=17 GKE_KONNECTIVITY_PROXY_UNSUPPORTED value + * @property {number} RESOURCE_CONFIG_NOT_FOUND=18 RESOURCE_CONFIG_NOT_FOUND value + * @property {number} VM_INSTANCE_CONFIG_NOT_FOUND=24 VM_INSTANCE_CONFIG_NOT_FOUND value + * @property {number} NETWORK_CONFIG_NOT_FOUND=25 NETWORK_CONFIG_NOT_FOUND value + * @property {number} FIREWALL_CONFIG_NOT_FOUND=26 FIREWALL_CONFIG_NOT_FOUND value + * @property {number} ROUTE_CONFIG_NOT_FOUND=27 ROUTE_CONFIG_NOT_FOUND value + * @property {number} GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT=19 GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT value + * @property {number} SOURCE_PSC_CLOUD_SQL_UNSUPPORTED=20 SOURCE_PSC_CLOUD_SQL_UNSUPPORTED value + * @property {number} SOURCE_REDIS_CLUSTER_UNSUPPORTED=34 SOURCE_REDIS_CLUSTER_UNSUPPORTED value + * @property {number} SOURCE_REDIS_INSTANCE_UNSUPPORTED=35 SOURCE_REDIS_INSTANCE_UNSUPPORTED value + * @property {number} SOURCE_FORWARDING_RULE_UNSUPPORTED=21 SOURCE_FORWARDING_RULE_UNSUPPORTED value + * @property {number} NON_ROUTABLE_IP_ADDRESS=22 NON_ROUTABLE_IP_ADDRESS value + * @property {number} UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT=30 UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT value + * @property {number} UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG=31 UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG value + */ + AbortInfo.Cause = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "CAUSE_UNSPECIFIED"] = 0; + values[valuesById[1] = "UNKNOWN_NETWORK"] = 1; + values[valuesById[3] = "UNKNOWN_PROJECT"] = 3; + values[valuesById[7] = "NO_EXTERNAL_IP"] = 7; + values[valuesById[8] = "UNINTENDED_DESTINATION"] = 8; + values[valuesById[11] = "SOURCE_ENDPOINT_NOT_FOUND"] = 11; + values[valuesById[12] = "MISMATCHED_SOURCE_NETWORK"] = 12; + values[valuesById[13] = "DESTINATION_ENDPOINT_NOT_FOUND"] = 13; + values[valuesById[14] = "MISMATCHED_DESTINATION_NETWORK"] = 14; + values[valuesById[2] = "UNKNOWN_IP"] = 2; + values[valuesById[32] = "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP"] = 32; + values[valuesById[23] = "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK"] = 23; + values[valuesById[4] = "PERMISSION_DENIED"] = 4; + values[valuesById[28] = "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS"] = 28; + values[valuesById[29] = "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS"] = 29; + values[valuesById[36] = "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS"] = 36; + values[valuesById[5] = "NO_SOURCE_LOCATION"] = 5; + values[valuesById[6] = "INVALID_ARGUMENT"] = 6; + values[valuesById[9] = "TRACE_TOO_LONG"] = 9; + values[valuesById[10] = "INTERNAL_ERROR"] = 10; + values[valuesById[15] = "UNSUPPORTED"] = 15; + values[valuesById[16] = "MISMATCHED_IP_VERSION"] = 16; + values[valuesById[17] = "GKE_KONNECTIVITY_PROXY_UNSUPPORTED"] = 17; + values[valuesById[18] = "RESOURCE_CONFIG_NOT_FOUND"] = 18; + values[valuesById[24] = "VM_INSTANCE_CONFIG_NOT_FOUND"] = 24; + values[valuesById[25] = "NETWORK_CONFIG_NOT_FOUND"] = 25; + values[valuesById[26] = "FIREWALL_CONFIG_NOT_FOUND"] = 26; + values[valuesById[27] = "ROUTE_CONFIG_NOT_FOUND"] = 27; + values[valuesById[19] = "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT"] = 19; + values[valuesById[20] = "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED"] = 20; + values[valuesById[34] = "SOURCE_REDIS_CLUSTER_UNSUPPORTED"] = 34; + values[valuesById[35] = "SOURCE_REDIS_INSTANCE_UNSUPPORTED"] = 35; + values[valuesById[21] = "SOURCE_FORWARDING_RULE_UNSUPPORTED"] = 21; + values[valuesById[22] = "NON_ROUTABLE_IP_ADDRESS"] = 22; + values[valuesById[30] = "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT"] = 30; + values[valuesById[31] = "UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG"] = 31; + return values; + })(); + + return AbortInfo; + })(); + + v1beta1.DropInfo = (function() { + + /** + * Properties of a DropInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IDropInfo + * @property {google.cloud.networkmanagement.v1beta1.DropInfo.Cause|null} [cause] DropInfo cause + * @property {string|null} [resourceUri] DropInfo resourceUri + * @property {string|null} [sourceIp] DropInfo sourceIp + * @property {string|null} [destinationIp] DropInfo destinationIp + * @property {string|null} [region] DropInfo region + */ + + /** + * Constructs a new DropInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a DropInfo. + * @implements IDropInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IDropInfo=} [properties] Properties to set + */ + function DropInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * DropInfo cause. + * @member {google.cloud.networkmanagement.v1beta1.DropInfo.Cause} cause + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + */ + DropInfo.prototype.cause = 0; + + /** + * DropInfo resourceUri. + * @member {string} resourceUri + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + */ + DropInfo.prototype.resourceUri = ""; + + /** + * DropInfo sourceIp. + * @member {string} sourceIp + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + */ + DropInfo.prototype.sourceIp = ""; + + /** + * DropInfo destinationIp. + * @member {string} destinationIp + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + */ + DropInfo.prototype.destinationIp = ""; + + /** + * DropInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + */ + DropInfo.prototype.region = ""; + + /** + * Creates a new DropInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDropInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo instance + */ + DropInfo.create = function create(properties) { + return new DropInfo(properties); + }; + + /** + * Encodes the specified DropInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DropInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDropInfo} message DropInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DropInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.cause != null && Object.hasOwnProperty.call(message, "cause")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.cause); + if (message.resourceUri != null && Object.hasOwnProperty.call(message, "resourceUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.resourceUri); + if (message.sourceIp != null && Object.hasOwnProperty.call(message, "sourceIp")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.sourceIp); + if (message.destinationIp != null && Object.hasOwnProperty.call(message, "destinationIp")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.destinationIp); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.region); + return writer; + }; + + /** + * Encodes the specified DropInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.DropInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IDropInfo} message DropInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DropInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a DropInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DropInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.DropInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.cause = reader.int32(); + break; + } + case 2: { + message.resourceUri = reader.string(); + break; + } + case 3: { + message.sourceIp = reader.string(); + break; + } + case 4: { + message.destinationIp = reader.string(); + break; + } + case 5: { + message.region = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a DropInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DropInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a DropInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DropInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.cause != null && message.hasOwnProperty("cause")) + switch (message.cause) { + default: + return "cause: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 42: + case 43: + case 49: + case 50: + case 51: + case 52: + case 53: + case 44: + case 45: + case 46: + case 7: + case 8: + case 47: + case 9: + case 10: + case 11: + case 12: + case 13: + case 14: + case 27: + case 28: + case 68: + case 69: + case 15: + case 16: + case 17: + case 18: + case 19: + case 20: + case 38: + case 36: + case 21: + case 30: + case 31: + case 32: + case 33: + case 34: + case 35: + case 63: + case 22: + case 23: + case 24: + case 60: + case 61: + case 25: + case 26: + case 41: + case 48: + case 54: + case 58: + case 57: + case 64: + case 55: + case 56: + case 29: + case 37: + case 39: + case 40: + case 59: + case 62: + case 65: + case 66: + case 67: + case 70: + case 71: + case 72: + case 73: + case 74: + case 78: + case 75: + case 76: + case 77: + case 79: + case 80: + case 81: + case 82: + break; + } + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + if (!$util.isString(message.resourceUri)) + return "resourceUri: string expected"; + if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) + if (!$util.isString(message.sourceIp)) + return "sourceIp: string expected"; + if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) + if (!$util.isString(message.destinationIp)) + return "destinationIp: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; + return null; + }; + + /** + * Creates a DropInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.DropInfo} DropInfo + */ + DropInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.DropInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.DropInfo(); + switch (object.cause) { + default: + if (typeof object.cause === "number") { + message.cause = object.cause; + break; + } + break; + case "CAUSE_UNSPECIFIED": + case 0: + message.cause = 0; + break; + case "UNKNOWN_EXTERNAL_ADDRESS": + case 1: + message.cause = 1; + break; + case "FOREIGN_IP_DISALLOWED": + case 2: + message.cause = 2; + break; + case "FIREWALL_RULE": + case 3: + message.cause = 3; + break; + case "NO_ROUTE": + case 4: + message.cause = 4; + break; + case "ROUTE_BLACKHOLE": + case 5: + message.cause = 5; + break; + case "ROUTE_WRONG_NETWORK": + case 6: + message.cause = 6; + break; + case "ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED": + case 42: + message.cause = 42; + break; + case "ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND": + case 43: + message.cause = 43; + break; + case "ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK": + case 49: + message.cause = 49; + break; + case "ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP": + case 50: + message.cause = 50; + break; + case "ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH": + case 51: + message.cause = 51; + break; + case "ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED": + case 52: + message.cause = 52; + break; + case "ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID": + case 53: + message.cause = 53; + break; + case "NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS": + case 44: + message.cause = 44; + break; + case "VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH": + case 45: + message.cause = 45; + break; + case "VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH": + case 46: + message.cause = 46; + break; + case "PRIVATE_TRAFFIC_TO_INTERNET": + case 7: + message.cause = 7; + break; + case "PRIVATE_GOOGLE_ACCESS_DISALLOWED": + case 8: + message.cause = 8; + break; + case "PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED": + case 47: + message.cause = 47; + break; + case "NO_EXTERNAL_ADDRESS": + case 9: + message.cause = 9; + break; + case "UNKNOWN_INTERNAL_ADDRESS": + case 10: + message.cause = 10; + break; + case "FORWARDING_RULE_MISMATCH": + case 11: + message.cause = 11; + break; + case "FORWARDING_RULE_NO_INSTANCES": + case 12: + message.cause = 12; + break; + case "FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK": + case 13: + message.cause = 13; + break; + case "INSTANCE_NOT_RUNNING": + case 14: + message.cause = 14; + break; + case "GKE_CLUSTER_NOT_RUNNING": + case 27: + message.cause = 27; + break; + case "CLOUD_SQL_INSTANCE_NOT_RUNNING": + case 28: + message.cause = 28; + break; + case "REDIS_INSTANCE_NOT_RUNNING": + case 68: + message.cause = 68; + break; + case "REDIS_CLUSTER_NOT_RUNNING": + case 69: + message.cause = 69; + break; + case "TRAFFIC_TYPE_BLOCKED": + case 15: + message.cause = 15; + break; + case "GKE_MASTER_UNAUTHORIZED_ACCESS": + case 16: + message.cause = 16; + break; + case "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS": + case 17: + message.cause = 17; + break; + case "DROPPED_INSIDE_GKE_SERVICE": + case 18: + message.cause = 18; + break; + case "DROPPED_INSIDE_CLOUD_SQL_SERVICE": + case 19: + message.cause = 19; + break; + case "GOOGLE_MANAGED_SERVICE_NO_PEERING": + case 20: + message.cause = 20; + break; + case "GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT": + case 38: + message.cause = 38; + break; + case "GKE_PSC_ENDPOINT_MISSING": + case 36: + message.cause = 36; + break; + case "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS": + case 21: + message.cause = 21; + break; + case "GKE_CONTROL_PLANE_REGION_MISMATCH": + case 30: + message.cause = 30; + break; + case "PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION": + case 31: + message.cause = 31; + break; + case "GKE_CONTROL_PLANE_NO_ROUTE": + case 32: + message.cause = 32; + break; + case "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC": + case 33: + message.cause = 33; + break; + case "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION": + case 34: + message.cause = 34; + break; + case "CLOUD_SQL_INSTANCE_NO_ROUTE": + case 35: + message.cause = 35; + break; + case "CLOUD_SQL_CONNECTOR_REQUIRED": + case 63: + message.cause = 63; + break; + case "CLOUD_FUNCTION_NOT_ACTIVE": + case 22: + message.cause = 22; + break; + case "VPC_CONNECTOR_NOT_SET": + case 23: + message.cause = 23; + break; + case "VPC_CONNECTOR_NOT_RUNNING": + case 24: + message.cause = 24; + break; + case "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED": + case 60: + message.cause = 60; + break; + case "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED": + case 61: + message.cause = 61; + break; + case "FORWARDING_RULE_REGION_MISMATCH": + case 25: + message.cause = 25; + break; + case "PSC_CONNECTION_NOT_ACCEPTED": + case 26: + message.cause = 26; + break; + case "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK": + case 41: message.cause = 41; break; case "PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS": @@ -28777,6 +30936,10 @@ case 57: message.cause = 57; break; + case "PSC_TRANSITIVITY_NOT_PROPAGATED": + case 64: + message.cause = 64; + break; case "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED": case 55: message.cause = 55; @@ -28805,231 +30968,939 @@ case 59: message.cause = 59; break; + case "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE": + case 62: + message.cause = 62; + break; + case "LOAD_BALANCER_BACKEND_INVALID_NETWORK": + case 65: + message.cause = 65; + break; + case "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED": + case 66: + message.cause = 66; + break; + case "DESTINATION_IS_PRIVATE_NAT_IP_RANGE": + case 67: + message.cause = 67; + break; + case "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE": + case 70: + message.cause = 70; + break; + case "REDIS_INSTANCE_UNSUPPORTED_PORT": + case 71: + message.cause = 71; + break; + case "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS": + case 72: + message.cause = 72; + break; + case "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK": + case 73: + message.cause = 73; + break; + case "REDIS_INSTANCE_NO_EXTERNAL_IP": + case 74: + message.cause = 74; + break; + case "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL": + case 78: + message.cause = 78; + break; + case "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE": + case 75: + message.cause = 75; + break; + case "REDIS_CLUSTER_UNSUPPORTED_PORT": + case 76: + message.cause = 76; + break; + case "REDIS_CLUSTER_NO_EXTERNAL_IP": + case 77: + message.cause = 77; + break; + case "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL": + case 79: + message.cause = 79; + break; + case "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION": + case 80: + message.cause = 80; + break; + case "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION": + case 81: + message.cause = 81; + break; + case "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION": + case 82: + message.cause = 82; + break; + } + if (object.resourceUri != null) + message.resourceUri = String(object.resourceUri); + if (object.sourceIp != null) + message.sourceIp = String(object.sourceIp); + if (object.destinationIp != null) + message.destinationIp = String(object.destinationIp); + if (object.region != null) + message.region = String(object.region); + return message; + }; + + /** + * Creates a plain object from a DropInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.DropInfo} message DropInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DropInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.cause = options.enums === String ? "CAUSE_UNSPECIFIED" : 0; + object.resourceUri = ""; + object.sourceIp = ""; + object.destinationIp = ""; + object.region = ""; + } + if (message.cause != null && message.hasOwnProperty("cause")) + object.cause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.DropInfo.Cause[message.cause] === undefined ? message.cause : $root.google.cloud.networkmanagement.v1beta1.DropInfo.Cause[message.cause] : message.cause; + if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) + object.resourceUri = message.resourceUri; + if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) + object.sourceIp = message.sourceIp; + if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) + object.destinationIp = message.destinationIp; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; + return object; + }; + + /** + * Converts this DropInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @instance + * @returns {Object.} JSON object + */ + DropInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for DropInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DropInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.DropInfo"; + }; + + /** + * Cause enum. + * @name google.cloud.networkmanagement.v1beta1.DropInfo.Cause + * @enum {number} + * @property {number} CAUSE_UNSPECIFIED=0 CAUSE_UNSPECIFIED value + * @property {number} UNKNOWN_EXTERNAL_ADDRESS=1 UNKNOWN_EXTERNAL_ADDRESS value + * @property {number} FOREIGN_IP_DISALLOWED=2 FOREIGN_IP_DISALLOWED value + * @property {number} FIREWALL_RULE=3 FIREWALL_RULE value + * @property {number} NO_ROUTE=4 NO_ROUTE value + * @property {number} ROUTE_BLACKHOLE=5 ROUTE_BLACKHOLE value + * @property {number} ROUTE_WRONG_NETWORK=6 ROUTE_WRONG_NETWORK value + * @property {number} ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED=42 ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED value + * @property {number} ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND=43 ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND value + * @property {number} ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK=49 ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK value + * @property {number} ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP=50 ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP value + * @property {number} ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH=51 ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH value + * @property {number} ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED=52 ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED value + * @property {number} ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID=53 ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID value + * @property {number} NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS=44 NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS value + * @property {number} VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH=45 VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH value + * @property {number} VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH=46 VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH value + * @property {number} PRIVATE_TRAFFIC_TO_INTERNET=7 PRIVATE_TRAFFIC_TO_INTERNET value + * @property {number} PRIVATE_GOOGLE_ACCESS_DISALLOWED=8 PRIVATE_GOOGLE_ACCESS_DISALLOWED value + * @property {number} PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED=47 PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED value + * @property {number} NO_EXTERNAL_ADDRESS=9 NO_EXTERNAL_ADDRESS value + * @property {number} UNKNOWN_INTERNAL_ADDRESS=10 UNKNOWN_INTERNAL_ADDRESS value + * @property {number} FORWARDING_RULE_MISMATCH=11 FORWARDING_RULE_MISMATCH value + * @property {number} FORWARDING_RULE_NO_INSTANCES=12 FORWARDING_RULE_NO_INSTANCES value + * @property {number} FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK=13 FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK value + * @property {number} INSTANCE_NOT_RUNNING=14 INSTANCE_NOT_RUNNING value + * @property {number} GKE_CLUSTER_NOT_RUNNING=27 GKE_CLUSTER_NOT_RUNNING value + * @property {number} CLOUD_SQL_INSTANCE_NOT_RUNNING=28 CLOUD_SQL_INSTANCE_NOT_RUNNING value + * @property {number} REDIS_INSTANCE_NOT_RUNNING=68 REDIS_INSTANCE_NOT_RUNNING value + * @property {number} REDIS_CLUSTER_NOT_RUNNING=69 REDIS_CLUSTER_NOT_RUNNING value + * @property {number} TRAFFIC_TYPE_BLOCKED=15 TRAFFIC_TYPE_BLOCKED value + * @property {number} GKE_MASTER_UNAUTHORIZED_ACCESS=16 GKE_MASTER_UNAUTHORIZED_ACCESS value + * @property {number} CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS=17 CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS value + * @property {number} DROPPED_INSIDE_GKE_SERVICE=18 DROPPED_INSIDE_GKE_SERVICE value + * @property {number} DROPPED_INSIDE_CLOUD_SQL_SERVICE=19 DROPPED_INSIDE_CLOUD_SQL_SERVICE value + * @property {number} GOOGLE_MANAGED_SERVICE_NO_PEERING=20 GOOGLE_MANAGED_SERVICE_NO_PEERING value + * @property {number} GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT=38 GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT value + * @property {number} GKE_PSC_ENDPOINT_MISSING=36 GKE_PSC_ENDPOINT_MISSING value + * @property {number} CLOUD_SQL_INSTANCE_NO_IP_ADDRESS=21 CLOUD_SQL_INSTANCE_NO_IP_ADDRESS value + * @property {number} GKE_CONTROL_PLANE_REGION_MISMATCH=30 GKE_CONTROL_PLANE_REGION_MISMATCH value + * @property {number} PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION=31 PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION value + * @property {number} GKE_CONTROL_PLANE_NO_ROUTE=32 GKE_CONTROL_PLANE_NO_ROUTE value + * @property {number} CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC=33 CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC value + * @property {number} PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION=34 PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION value + * @property {number} CLOUD_SQL_INSTANCE_NO_ROUTE=35 CLOUD_SQL_INSTANCE_NO_ROUTE value + * @property {number} CLOUD_SQL_CONNECTOR_REQUIRED=63 CLOUD_SQL_CONNECTOR_REQUIRED value + * @property {number} CLOUD_FUNCTION_NOT_ACTIVE=22 CLOUD_FUNCTION_NOT_ACTIVE value + * @property {number} VPC_CONNECTOR_NOT_SET=23 VPC_CONNECTOR_NOT_SET value + * @property {number} VPC_CONNECTOR_NOT_RUNNING=24 VPC_CONNECTOR_NOT_RUNNING value + * @property {number} VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED=60 VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED value + * @property {number} VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED=61 VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED value + * @property {number} FORWARDING_RULE_REGION_MISMATCH=25 FORWARDING_RULE_REGION_MISMATCH value + * @property {number} PSC_CONNECTION_NOT_ACCEPTED=26 PSC_CONNECTION_NOT_ACCEPTED value + * @property {number} PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK=41 PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK value + * @property {number} PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS=48 PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS value + * @property {number} PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS=54 PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS value + * @property {number} CLOUD_SQL_PSC_NEG_UNSUPPORTED=58 CLOUD_SQL_PSC_NEG_UNSUPPORTED value + * @property {number} NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT=57 NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT value + * @property {number} PSC_TRANSITIVITY_NOT_PROPAGATED=64 PSC_TRANSITIVITY_NOT_PROPAGATED value + * @property {number} HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED=55 HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED value + * @property {number} HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED=56 HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED value + * @property {number} CLOUD_RUN_REVISION_NOT_READY=29 CLOUD_RUN_REVISION_NOT_READY value + * @property {number} DROPPED_INSIDE_PSC_SERVICE_PRODUCER=37 DROPPED_INSIDE_PSC_SERVICE_PRODUCER value + * @property {number} LOAD_BALANCER_HAS_NO_PROXY_SUBNET=39 LOAD_BALANCER_HAS_NO_PROXY_SUBNET value + * @property {number} CLOUD_NAT_NO_ADDRESSES=40 CLOUD_NAT_NO_ADDRESSES value + * @property {number} ROUTING_LOOP=59 ROUTING_LOOP value + * @property {number} DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE=62 DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE value + * @property {number} LOAD_BALANCER_BACKEND_INVALID_NETWORK=65 LOAD_BALANCER_BACKEND_INVALID_NETWORK value + * @property {number} BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED=66 BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED value + * @property {number} DESTINATION_IS_PRIVATE_NAT_IP_RANGE=67 DESTINATION_IS_PRIVATE_NAT_IP_RANGE value + * @property {number} DROPPED_INSIDE_REDIS_INSTANCE_SERVICE=70 DROPPED_INSIDE_REDIS_INSTANCE_SERVICE value + * @property {number} REDIS_INSTANCE_UNSUPPORTED_PORT=71 REDIS_INSTANCE_UNSUPPORTED_PORT value + * @property {number} REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS=72 REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS value + * @property {number} REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK=73 REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK value + * @property {number} REDIS_INSTANCE_NO_EXTERNAL_IP=74 REDIS_INSTANCE_NO_EXTERNAL_IP value + * @property {number} REDIS_INSTANCE_UNSUPPORTED_PROTOCOL=78 REDIS_INSTANCE_UNSUPPORTED_PROTOCOL value + * @property {number} DROPPED_INSIDE_REDIS_CLUSTER_SERVICE=75 DROPPED_INSIDE_REDIS_CLUSTER_SERVICE value + * @property {number} REDIS_CLUSTER_UNSUPPORTED_PORT=76 REDIS_CLUSTER_UNSUPPORTED_PORT value + * @property {number} REDIS_CLUSTER_NO_EXTERNAL_IP=77 REDIS_CLUSTER_NO_EXTERNAL_IP value + * @property {number} REDIS_CLUSTER_UNSUPPORTED_PROTOCOL=79 REDIS_CLUSTER_UNSUPPORTED_PROTOCOL value + * @property {number} NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION=80 NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION value + * @property {number} NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION=81 NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION value + * @property {number} NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION=82 NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION value + */ + DropInfo.Cause = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "CAUSE_UNSPECIFIED"] = 0; + values[valuesById[1] = "UNKNOWN_EXTERNAL_ADDRESS"] = 1; + values[valuesById[2] = "FOREIGN_IP_DISALLOWED"] = 2; + values[valuesById[3] = "FIREWALL_RULE"] = 3; + values[valuesById[4] = "NO_ROUTE"] = 4; + values[valuesById[5] = "ROUTE_BLACKHOLE"] = 5; + values[valuesById[6] = "ROUTE_WRONG_NETWORK"] = 6; + values[valuesById[42] = "ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED"] = 42; + values[valuesById[43] = "ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND"] = 43; + values[valuesById[49] = "ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK"] = 49; + values[valuesById[50] = "ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP"] = 50; + values[valuesById[51] = "ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH"] = 51; + values[valuesById[52] = "ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED"] = 52; + values[valuesById[53] = "ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID"] = 53; + values[valuesById[44] = "NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS"] = 44; + values[valuesById[45] = "VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH"] = 45; + values[valuesById[46] = "VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH"] = 46; + values[valuesById[7] = "PRIVATE_TRAFFIC_TO_INTERNET"] = 7; + values[valuesById[8] = "PRIVATE_GOOGLE_ACCESS_DISALLOWED"] = 8; + values[valuesById[47] = "PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED"] = 47; + values[valuesById[9] = "NO_EXTERNAL_ADDRESS"] = 9; + values[valuesById[10] = "UNKNOWN_INTERNAL_ADDRESS"] = 10; + values[valuesById[11] = "FORWARDING_RULE_MISMATCH"] = 11; + values[valuesById[12] = "FORWARDING_RULE_NO_INSTANCES"] = 12; + values[valuesById[13] = "FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK"] = 13; + values[valuesById[14] = "INSTANCE_NOT_RUNNING"] = 14; + values[valuesById[27] = "GKE_CLUSTER_NOT_RUNNING"] = 27; + values[valuesById[28] = "CLOUD_SQL_INSTANCE_NOT_RUNNING"] = 28; + values[valuesById[68] = "REDIS_INSTANCE_NOT_RUNNING"] = 68; + values[valuesById[69] = "REDIS_CLUSTER_NOT_RUNNING"] = 69; + values[valuesById[15] = "TRAFFIC_TYPE_BLOCKED"] = 15; + values[valuesById[16] = "GKE_MASTER_UNAUTHORIZED_ACCESS"] = 16; + values[valuesById[17] = "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS"] = 17; + values[valuesById[18] = "DROPPED_INSIDE_GKE_SERVICE"] = 18; + values[valuesById[19] = "DROPPED_INSIDE_CLOUD_SQL_SERVICE"] = 19; + values[valuesById[20] = "GOOGLE_MANAGED_SERVICE_NO_PEERING"] = 20; + values[valuesById[38] = "GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT"] = 38; + values[valuesById[36] = "GKE_PSC_ENDPOINT_MISSING"] = 36; + values[valuesById[21] = "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS"] = 21; + values[valuesById[30] = "GKE_CONTROL_PLANE_REGION_MISMATCH"] = 30; + values[valuesById[31] = "PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION"] = 31; + values[valuesById[32] = "GKE_CONTROL_PLANE_NO_ROUTE"] = 32; + values[valuesById[33] = "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC"] = 33; + values[valuesById[34] = "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION"] = 34; + values[valuesById[35] = "CLOUD_SQL_INSTANCE_NO_ROUTE"] = 35; + values[valuesById[63] = "CLOUD_SQL_CONNECTOR_REQUIRED"] = 63; + values[valuesById[22] = "CLOUD_FUNCTION_NOT_ACTIVE"] = 22; + values[valuesById[23] = "VPC_CONNECTOR_NOT_SET"] = 23; + values[valuesById[24] = "VPC_CONNECTOR_NOT_RUNNING"] = 24; + values[valuesById[60] = "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED"] = 60; + values[valuesById[61] = "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED"] = 61; + values[valuesById[25] = "FORWARDING_RULE_REGION_MISMATCH"] = 25; + values[valuesById[26] = "PSC_CONNECTION_NOT_ACCEPTED"] = 26; + values[valuesById[41] = "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK"] = 41; + values[valuesById[48] = "PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS"] = 48; + values[valuesById[54] = "PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS"] = 54; + values[valuesById[58] = "CLOUD_SQL_PSC_NEG_UNSUPPORTED"] = 58; + values[valuesById[57] = "NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT"] = 57; + values[valuesById[64] = "PSC_TRANSITIVITY_NOT_PROPAGATED"] = 64; + values[valuesById[55] = "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED"] = 55; + values[valuesById[56] = "HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED"] = 56; + values[valuesById[29] = "CLOUD_RUN_REVISION_NOT_READY"] = 29; + values[valuesById[37] = "DROPPED_INSIDE_PSC_SERVICE_PRODUCER"] = 37; + values[valuesById[39] = "LOAD_BALANCER_HAS_NO_PROXY_SUBNET"] = 39; + values[valuesById[40] = "CLOUD_NAT_NO_ADDRESSES"] = 40; + values[valuesById[59] = "ROUTING_LOOP"] = 59; + values[valuesById[62] = "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE"] = 62; + values[valuesById[65] = "LOAD_BALANCER_BACKEND_INVALID_NETWORK"] = 65; + values[valuesById[66] = "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED"] = 66; + values[valuesById[67] = "DESTINATION_IS_PRIVATE_NAT_IP_RANGE"] = 67; + values[valuesById[70] = "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE"] = 70; + values[valuesById[71] = "REDIS_INSTANCE_UNSUPPORTED_PORT"] = 71; + values[valuesById[72] = "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS"] = 72; + values[valuesById[73] = "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK"] = 73; + values[valuesById[74] = "REDIS_INSTANCE_NO_EXTERNAL_IP"] = 74; + values[valuesById[78] = "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL"] = 78; + values[valuesById[75] = "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE"] = 75; + values[valuesById[76] = "REDIS_CLUSTER_UNSUPPORTED_PORT"] = 76; + values[valuesById[77] = "REDIS_CLUSTER_NO_EXTERNAL_IP"] = 77; + values[valuesById[79] = "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL"] = 79; + values[valuesById[80] = "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION"] = 80; + values[valuesById[81] = "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION"] = 81; + values[valuesById[82] = "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION"] = 82; + return values; + })(); + + return DropInfo; + })(); + + v1beta1.GKEMasterInfo = (function() { + + /** + * Properties of a GKEMasterInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IGKEMasterInfo + * @property {string|null} [clusterUri] GKEMasterInfo clusterUri + * @property {string|null} [clusterNetworkUri] GKEMasterInfo clusterNetworkUri + * @property {string|null} [internalIp] GKEMasterInfo internalIp + * @property {string|null} [externalIp] GKEMasterInfo externalIp + */ + + /** + * Constructs a new GKEMasterInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a GKEMasterInfo. + * @implements IGKEMasterInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo=} [properties] Properties to set + */ + function GKEMasterInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * GKEMasterInfo clusterUri. + * @member {string} clusterUri + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @instance + */ + GKEMasterInfo.prototype.clusterUri = ""; + + /** + * GKEMasterInfo clusterNetworkUri. + * @member {string} clusterNetworkUri + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @instance + */ + GKEMasterInfo.prototype.clusterNetworkUri = ""; + + /** + * GKEMasterInfo internalIp. + * @member {string} internalIp + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @instance + */ + GKEMasterInfo.prototype.internalIp = ""; + + /** + * GKEMasterInfo externalIp. + * @member {string} externalIp + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @instance + */ + GKEMasterInfo.prototype.externalIp = ""; + + /** + * Creates a new GKEMasterInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo instance + */ + GKEMasterInfo.create = function create(properties) { + return new GKEMasterInfo(properties); + }; + + /** + * Encodes the specified GKEMasterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo} message GKEMasterInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GKEMasterInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.clusterUri != null && Object.hasOwnProperty.call(message, "clusterUri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.clusterUri); + if (message.clusterNetworkUri != null && Object.hasOwnProperty.call(message, "clusterNetworkUri")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.clusterNetworkUri); + if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); + if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); + return writer; + }; + + /** + * Encodes the specified GKEMasterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo} message GKEMasterInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GKEMasterInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a GKEMasterInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GKEMasterInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 2: { + message.clusterUri = reader.string(); + break; + } + case 4: { + message.clusterNetworkUri = reader.string(); + break; + } + case 5: { + message.internalIp = reader.string(); + break; + } + case 6: { + message.externalIp = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a GKEMasterInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GKEMasterInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a GKEMasterInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GKEMasterInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.clusterUri != null && message.hasOwnProperty("clusterUri")) + if (!$util.isString(message.clusterUri)) + return "clusterUri: string expected"; + if (message.clusterNetworkUri != null && message.hasOwnProperty("clusterNetworkUri")) + if (!$util.isString(message.clusterNetworkUri)) + return "clusterNetworkUri: string expected"; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + if (!$util.isString(message.internalIp)) + return "internalIp: string expected"; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + if (!$util.isString(message.externalIp)) + return "externalIp: string expected"; + return null; + }; + + /** + * Creates a GKEMasterInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + */ + GKEMasterInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo(); + if (object.clusterUri != null) + message.clusterUri = String(object.clusterUri); + if (object.clusterNetworkUri != null) + message.clusterNetworkUri = String(object.clusterNetworkUri); + if (object.internalIp != null) + message.internalIp = String(object.internalIp); + if (object.externalIp != null) + message.externalIp = String(object.externalIp); + return message; + }; + + /** + * Creates a plain object from a GKEMasterInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} message GKEMasterInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GKEMasterInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.clusterUri = ""; + object.clusterNetworkUri = ""; + object.internalIp = ""; + object.externalIp = ""; + } + if (message.clusterUri != null && message.hasOwnProperty("clusterUri")) + object.clusterUri = message.clusterUri; + if (message.clusterNetworkUri != null && message.hasOwnProperty("clusterNetworkUri")) + object.clusterNetworkUri = message.clusterNetworkUri; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + object.internalIp = message.internalIp; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + object.externalIp = message.externalIp; + return object; + }; + + /** + * Converts this GKEMasterInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @instance + * @returns {Object.} JSON object + */ + GKEMasterInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for GKEMasterInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + GKEMasterInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.GKEMasterInfo"; + }; + + return GKEMasterInfo; + })(); + + v1beta1.CloudSQLInstanceInfo = (function() { + + /** + * Properties of a CloudSQLInstanceInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface ICloudSQLInstanceInfo + * @property {string|null} [displayName] CloudSQLInstanceInfo displayName + * @property {string|null} [uri] CloudSQLInstanceInfo uri + * @property {string|null} [networkUri] CloudSQLInstanceInfo networkUri + * @property {string|null} [internalIp] CloudSQLInstanceInfo internalIp + * @property {string|null} [externalIp] CloudSQLInstanceInfo externalIp + * @property {string|null} [region] CloudSQLInstanceInfo region + */ + + /** + * Constructs a new CloudSQLInstanceInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a CloudSQLInstanceInfo. + * @implements ICloudSQLInstanceInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo=} [properties] Properties to set + */ + function CloudSQLInstanceInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * CloudSQLInstanceInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.displayName = ""; + + /** + * CloudSQLInstanceInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.uri = ""; + + /** + * CloudSQLInstanceInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.networkUri = ""; + + /** + * CloudSQLInstanceInfo internalIp. + * @member {string} internalIp + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.internalIp = ""; + + /** + * CloudSQLInstanceInfo externalIp. + * @member {string} externalIp + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.externalIp = ""; + + /** + * CloudSQLInstanceInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + */ + CloudSQLInstanceInfo.prototype.region = ""; + + /** + * Creates a new CloudSQLInstanceInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo instance + */ + CloudSQLInstanceInfo.create = function create(properties) { + return new CloudSQLInstanceInfo(properties); + }; + + /** + * Encodes the specified CloudSQLInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo} message CloudSQLInstanceInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudSQLInstanceInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.networkUri); + if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); + if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.region); + return writer; + }; + + /** + * Encodes the specified CloudSQLInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo} message CloudSQLInstanceInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CloudSQLInstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a CloudSQLInstanceInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CloudSQLInstanceInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + case 2: { + message.uri = reader.string(); + break; + } + case 4: { + message.networkUri = reader.string(); + break; + } + case 5: { + message.internalIp = reader.string(); + break; + } + case 6: { + message.externalIp = reader.string(); + break; + } + case 7: { + message.region = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } } - if (object.resourceUri != null) - message.resourceUri = String(object.resourceUri); - if (object.sourceIp != null) - message.sourceIp = String(object.sourceIp); - if (object.destinationIp != null) - message.destinationIp = String(object.destinationIp); - if (object.region != null) - message.region = String(object.region); return message; }; /** - * Creates a plain object from a DropInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * Decodes a CloudSQLInstanceInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.DropInfo} message DropInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - DropInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.cause = options.enums === String ? "CAUSE_UNSPECIFIED" : 0; - object.resourceUri = ""; - object.sourceIp = ""; - object.destinationIp = ""; - object.region = ""; - } - if (message.cause != null && message.hasOwnProperty("cause")) - object.cause = options.enums === String ? $root.google.cloud.networkmanagement.v1beta1.DropInfo.Cause[message.cause] === undefined ? message.cause : $root.google.cloud.networkmanagement.v1beta1.DropInfo.Cause[message.cause] : message.cause; - if (message.resourceUri != null && message.hasOwnProperty("resourceUri")) - object.resourceUri = message.resourceUri; - if (message.sourceIp != null && message.hasOwnProperty("sourceIp")) - object.sourceIp = message.sourceIp; - if (message.destinationIp != null && message.hasOwnProperty("destinationIp")) - object.destinationIp = message.destinationIp; - if (message.region != null && message.hasOwnProperty("region")) - object.region = message.region; - return object; - }; - - /** - * Converts this DropInfo to JSON. - * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo - * @instance - * @returns {Object.} JSON object + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DropInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + CloudSQLInstanceInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Gets the default type url for DropInfo - * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.DropInfo + * Verifies a CloudSQLInstanceInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DropInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.DropInfo"; + CloudSQLInstanceInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + if (!$util.isString(message.internalIp)) + return "internalIp: string expected"; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + if (!$util.isString(message.externalIp)) + return "externalIp: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; + return null; }; /** - * Cause enum. - * @name google.cloud.networkmanagement.v1beta1.DropInfo.Cause - * @enum {number} - * @property {number} CAUSE_UNSPECIFIED=0 CAUSE_UNSPECIFIED value - * @property {number} UNKNOWN_EXTERNAL_ADDRESS=1 UNKNOWN_EXTERNAL_ADDRESS value - * @property {number} FOREIGN_IP_DISALLOWED=2 FOREIGN_IP_DISALLOWED value - * @property {number} FIREWALL_RULE=3 FIREWALL_RULE value - * @property {number} NO_ROUTE=4 NO_ROUTE value - * @property {number} ROUTE_BLACKHOLE=5 ROUTE_BLACKHOLE value - * @property {number} ROUTE_WRONG_NETWORK=6 ROUTE_WRONG_NETWORK value - * @property {number} ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED=42 ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED value - * @property {number} ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND=43 ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND value - * @property {number} ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK=49 ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK value - * @property {number} ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP=50 ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP value - * @property {number} ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH=51 ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH value - * @property {number} ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED=52 ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED value - * @property {number} ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID=53 ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID value - * @property {number} NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS=44 NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS value - * @property {number} VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH=45 VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH value - * @property {number} VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH=46 VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH value - * @property {number} PRIVATE_TRAFFIC_TO_INTERNET=7 PRIVATE_TRAFFIC_TO_INTERNET value - * @property {number} PRIVATE_GOOGLE_ACCESS_DISALLOWED=8 PRIVATE_GOOGLE_ACCESS_DISALLOWED value - * @property {number} PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED=47 PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED value - * @property {number} NO_EXTERNAL_ADDRESS=9 NO_EXTERNAL_ADDRESS value - * @property {number} UNKNOWN_INTERNAL_ADDRESS=10 UNKNOWN_INTERNAL_ADDRESS value - * @property {number} FORWARDING_RULE_MISMATCH=11 FORWARDING_RULE_MISMATCH value - * @property {number} FORWARDING_RULE_NO_INSTANCES=12 FORWARDING_RULE_NO_INSTANCES value - * @property {number} FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK=13 FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK value - * @property {number} INSTANCE_NOT_RUNNING=14 INSTANCE_NOT_RUNNING value - * @property {number} GKE_CLUSTER_NOT_RUNNING=27 GKE_CLUSTER_NOT_RUNNING value - * @property {number} CLOUD_SQL_INSTANCE_NOT_RUNNING=28 CLOUD_SQL_INSTANCE_NOT_RUNNING value - * @property {number} TRAFFIC_TYPE_BLOCKED=15 TRAFFIC_TYPE_BLOCKED value - * @property {number} GKE_MASTER_UNAUTHORIZED_ACCESS=16 GKE_MASTER_UNAUTHORIZED_ACCESS value - * @property {number} CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS=17 CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS value - * @property {number} DROPPED_INSIDE_GKE_SERVICE=18 DROPPED_INSIDE_GKE_SERVICE value - * @property {number} DROPPED_INSIDE_CLOUD_SQL_SERVICE=19 DROPPED_INSIDE_CLOUD_SQL_SERVICE value - * @property {number} GOOGLE_MANAGED_SERVICE_NO_PEERING=20 GOOGLE_MANAGED_SERVICE_NO_PEERING value - * @property {number} GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT=38 GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT value - * @property {number} GKE_PSC_ENDPOINT_MISSING=36 GKE_PSC_ENDPOINT_MISSING value - * @property {number} CLOUD_SQL_INSTANCE_NO_IP_ADDRESS=21 CLOUD_SQL_INSTANCE_NO_IP_ADDRESS value - * @property {number} GKE_CONTROL_PLANE_REGION_MISMATCH=30 GKE_CONTROL_PLANE_REGION_MISMATCH value - * @property {number} PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION=31 PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION value - * @property {number} GKE_CONTROL_PLANE_NO_ROUTE=32 GKE_CONTROL_PLANE_NO_ROUTE value - * @property {number} CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC=33 CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC value - * @property {number} PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION=34 PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION value - * @property {number} CLOUD_SQL_INSTANCE_NO_ROUTE=35 CLOUD_SQL_INSTANCE_NO_ROUTE value - * @property {number} CLOUD_FUNCTION_NOT_ACTIVE=22 CLOUD_FUNCTION_NOT_ACTIVE value - * @property {number} VPC_CONNECTOR_NOT_SET=23 VPC_CONNECTOR_NOT_SET value - * @property {number} VPC_CONNECTOR_NOT_RUNNING=24 VPC_CONNECTOR_NOT_RUNNING value - * @property {number} FORWARDING_RULE_REGION_MISMATCH=25 FORWARDING_RULE_REGION_MISMATCH value - * @property {number} PSC_CONNECTION_NOT_ACCEPTED=26 PSC_CONNECTION_NOT_ACCEPTED value - * @property {number} PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK=41 PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK value - * @property {number} PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS=48 PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS value - * @property {number} PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS=54 PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS value - * @property {number} CLOUD_SQL_PSC_NEG_UNSUPPORTED=58 CLOUD_SQL_PSC_NEG_UNSUPPORTED value - * @property {number} NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT=57 NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT value - * @property {number} HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED=55 HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED value - * @property {number} HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED=56 HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED value - * @property {number} CLOUD_RUN_REVISION_NOT_READY=29 CLOUD_RUN_REVISION_NOT_READY value - * @property {number} DROPPED_INSIDE_PSC_SERVICE_PRODUCER=37 DROPPED_INSIDE_PSC_SERVICE_PRODUCER value - * @property {number} LOAD_BALANCER_HAS_NO_PROXY_SUBNET=39 LOAD_BALANCER_HAS_NO_PROXY_SUBNET value - * @property {number} CLOUD_NAT_NO_ADDRESSES=40 CLOUD_NAT_NO_ADDRESSES value - * @property {number} ROUTING_LOOP=59 ROUTING_LOOP value + * Creates a CloudSQLInstanceInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo */ - DropInfo.Cause = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "CAUSE_UNSPECIFIED"] = 0; - values[valuesById[1] = "UNKNOWN_EXTERNAL_ADDRESS"] = 1; - values[valuesById[2] = "FOREIGN_IP_DISALLOWED"] = 2; - values[valuesById[3] = "FIREWALL_RULE"] = 3; - values[valuesById[4] = "NO_ROUTE"] = 4; - values[valuesById[5] = "ROUTE_BLACKHOLE"] = 5; - values[valuesById[6] = "ROUTE_WRONG_NETWORK"] = 6; - values[valuesById[42] = "ROUTE_NEXT_HOP_IP_ADDRESS_NOT_RESOLVED"] = 42; - values[valuesById[43] = "ROUTE_NEXT_HOP_RESOURCE_NOT_FOUND"] = 43; - values[valuesById[49] = "ROUTE_NEXT_HOP_INSTANCE_WRONG_NETWORK"] = 49; - values[valuesById[50] = "ROUTE_NEXT_HOP_INSTANCE_NON_PRIMARY_IP"] = 50; - values[valuesById[51] = "ROUTE_NEXT_HOP_FORWARDING_RULE_IP_MISMATCH"] = 51; - values[valuesById[52] = "ROUTE_NEXT_HOP_VPN_TUNNEL_NOT_ESTABLISHED"] = 52; - values[valuesById[53] = "ROUTE_NEXT_HOP_FORWARDING_RULE_TYPE_INVALID"] = 53; - values[valuesById[44] = "NO_ROUTE_FROM_INTERNET_TO_PRIVATE_IPV6_ADDRESS"] = 44; - values[valuesById[45] = "VPN_TUNNEL_LOCAL_SELECTOR_MISMATCH"] = 45; - values[valuesById[46] = "VPN_TUNNEL_REMOTE_SELECTOR_MISMATCH"] = 46; - values[valuesById[7] = "PRIVATE_TRAFFIC_TO_INTERNET"] = 7; - values[valuesById[8] = "PRIVATE_GOOGLE_ACCESS_DISALLOWED"] = 8; - values[valuesById[47] = "PRIVATE_GOOGLE_ACCESS_VIA_VPN_TUNNEL_UNSUPPORTED"] = 47; - values[valuesById[9] = "NO_EXTERNAL_ADDRESS"] = 9; - values[valuesById[10] = "UNKNOWN_INTERNAL_ADDRESS"] = 10; - values[valuesById[11] = "FORWARDING_RULE_MISMATCH"] = 11; - values[valuesById[12] = "FORWARDING_RULE_NO_INSTANCES"] = 12; - values[valuesById[13] = "FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK"] = 13; - values[valuesById[14] = "INSTANCE_NOT_RUNNING"] = 14; - values[valuesById[27] = "GKE_CLUSTER_NOT_RUNNING"] = 27; - values[valuesById[28] = "CLOUD_SQL_INSTANCE_NOT_RUNNING"] = 28; - values[valuesById[15] = "TRAFFIC_TYPE_BLOCKED"] = 15; - values[valuesById[16] = "GKE_MASTER_UNAUTHORIZED_ACCESS"] = 16; - values[valuesById[17] = "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS"] = 17; - values[valuesById[18] = "DROPPED_INSIDE_GKE_SERVICE"] = 18; - values[valuesById[19] = "DROPPED_INSIDE_CLOUD_SQL_SERVICE"] = 19; - values[valuesById[20] = "GOOGLE_MANAGED_SERVICE_NO_PEERING"] = 20; - values[valuesById[38] = "GOOGLE_MANAGED_SERVICE_NO_PSC_ENDPOINT"] = 38; - values[valuesById[36] = "GKE_PSC_ENDPOINT_MISSING"] = 36; - values[valuesById[21] = "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS"] = 21; - values[valuesById[30] = "GKE_CONTROL_PLANE_REGION_MISMATCH"] = 30; - values[valuesById[31] = "PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION"] = 31; - values[valuesById[32] = "GKE_CONTROL_PLANE_NO_ROUTE"] = 32; - values[valuesById[33] = "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC"] = 33; - values[valuesById[34] = "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION"] = 34; - values[valuesById[35] = "CLOUD_SQL_INSTANCE_NO_ROUTE"] = 35; - values[valuesById[22] = "CLOUD_FUNCTION_NOT_ACTIVE"] = 22; - values[valuesById[23] = "VPC_CONNECTOR_NOT_SET"] = 23; - values[valuesById[24] = "VPC_CONNECTOR_NOT_RUNNING"] = 24; - values[valuesById[25] = "FORWARDING_RULE_REGION_MISMATCH"] = 25; - values[valuesById[26] = "PSC_CONNECTION_NOT_ACCEPTED"] = 26; - values[valuesById[41] = "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK"] = 41; - values[valuesById[48] = "PSC_NEG_PRODUCER_ENDPOINT_NO_GLOBAL_ACCESS"] = 48; - values[valuesById[54] = "PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS"] = 54; - values[valuesById[58] = "CLOUD_SQL_PSC_NEG_UNSUPPORTED"] = 58; - values[valuesById[57] = "NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT"] = 57; - values[valuesById[55] = "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED"] = 55; - values[valuesById[56] = "HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED"] = 56; - values[valuesById[29] = "CLOUD_RUN_REVISION_NOT_READY"] = 29; - values[valuesById[37] = "DROPPED_INSIDE_PSC_SERVICE_PRODUCER"] = 37; - values[valuesById[39] = "LOAD_BALANCER_HAS_NO_PROXY_SUBNET"] = 39; - values[valuesById[40] = "CLOUD_NAT_NO_ADDRESSES"] = 40; - values[valuesById[59] = "ROUTING_LOOP"] = 59; - return values; - })(); + CloudSQLInstanceInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.internalIp != null) + message.internalIp = String(object.internalIp); + if (object.externalIp != null) + message.externalIp = String(object.externalIp); + if (object.region != null) + message.region = String(object.region); + return message; + }; - return DropInfo; + /** + * Creates a plain object from a CloudSQLInstanceInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} message CloudSQLInstanceInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CloudSQLInstanceInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.displayName = ""; + object.uri = ""; + object.networkUri = ""; + object.internalIp = ""; + object.externalIp = ""; + object.region = ""; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.internalIp != null && message.hasOwnProperty("internalIp")) + object.internalIp = message.internalIp; + if (message.externalIp != null && message.hasOwnProperty("externalIp")) + object.externalIp = message.externalIp; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; + return object; + }; + + /** + * Converts this CloudSQLInstanceInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @instance + * @returns {Object.} JSON object + */ + CloudSQLInstanceInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for CloudSQLInstanceInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CloudSQLInstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo"; + }; + + return CloudSQLInstanceInfo; })(); - v1beta1.GKEMasterInfo = (function() { + v1beta1.RedisInstanceInfo = (function() { /** - * Properties of a GKEMasterInfo. + * Properties of a RedisInstanceInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface IGKEMasterInfo - * @property {string|null} [clusterUri] GKEMasterInfo clusterUri - * @property {string|null} [clusterNetworkUri] GKEMasterInfo clusterNetworkUri - * @property {string|null} [internalIp] GKEMasterInfo internalIp - * @property {string|null} [externalIp] GKEMasterInfo externalIp + * @interface IRedisInstanceInfo + * @property {string|null} [displayName] RedisInstanceInfo displayName + * @property {string|null} [uri] RedisInstanceInfo uri + * @property {string|null} [networkUri] RedisInstanceInfo networkUri + * @property {string|null} [primaryEndpointIp] RedisInstanceInfo primaryEndpointIp + * @property {string|null} [readEndpointIp] RedisInstanceInfo readEndpointIp + * @property {string|null} [region] RedisInstanceInfo region */ /** - * Constructs a new GKEMasterInfo. + * Constructs a new RedisInstanceInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a GKEMasterInfo. - * @implements IGKEMasterInfo + * @classdesc Represents a RedisInstanceInfo. + * @implements IRedisInstanceInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo=} [properties] Properties to set */ - function GKEMasterInfo(properties) { + function RedisInstanceInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -29037,117 +31908,145 @@ } /** - * GKEMasterInfo clusterUri. - * @member {string} clusterUri - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * RedisInstanceInfo displayName. + * @member {string} displayName + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @instance */ - GKEMasterInfo.prototype.clusterUri = ""; + RedisInstanceInfo.prototype.displayName = ""; /** - * GKEMasterInfo clusterNetworkUri. - * @member {string} clusterNetworkUri - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * RedisInstanceInfo uri. + * @member {string} uri + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @instance */ - GKEMasterInfo.prototype.clusterNetworkUri = ""; + RedisInstanceInfo.prototype.uri = ""; /** - * GKEMasterInfo internalIp. - * @member {string} internalIp - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * RedisInstanceInfo networkUri. + * @member {string} networkUri + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @instance */ - GKEMasterInfo.prototype.internalIp = ""; + RedisInstanceInfo.prototype.networkUri = ""; /** - * GKEMasterInfo externalIp. - * @member {string} externalIp - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * RedisInstanceInfo primaryEndpointIp. + * @member {string} primaryEndpointIp + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @instance */ - GKEMasterInfo.prototype.externalIp = ""; + RedisInstanceInfo.prototype.primaryEndpointIp = ""; /** - * Creates a new GKEMasterInfo instance using the specified properties. + * RedisInstanceInfo readEndpointIp. + * @member {string} readEndpointIp + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo + * @instance + */ + RedisInstanceInfo.prototype.readEndpointIp = ""; + + /** + * RedisInstanceInfo region. + * @member {string} region + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo + * @instance + */ + RedisInstanceInfo.prototype.region = ""; + + /** + * Creates a new RedisInstanceInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.RedisInstanceInfo} RedisInstanceInfo instance */ - GKEMasterInfo.create = function create(properties) { - return new GKEMasterInfo(properties); + RedisInstanceInfo.create = function create(properties) { + return new RedisInstanceInfo(properties); }; /** - * Encodes the specified GKEMasterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify|verify} messages. + * Encodes the specified RedisInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo} message GKEMasterInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo} message RedisInstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GKEMasterInfo.encode = function encode(message, writer) { + RedisInstanceInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.clusterUri != null && Object.hasOwnProperty.call(message, "clusterUri")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.clusterUri); - if (message.clusterNetworkUri != null && Object.hasOwnProperty.call(message, "clusterNetworkUri")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.clusterNetworkUri); - if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); - if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); + if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); + if (message.primaryEndpointIp != null && Object.hasOwnProperty.call(message, "primaryEndpointIp")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.primaryEndpointIp); + if (message.readEndpointIp != null && Object.hasOwnProperty.call(message, "readEndpointIp")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.readEndpointIp); + if (message.region != null && Object.hasOwnProperty.call(message, "region")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.region); return writer; }; /** - * Encodes the specified GKEMasterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.GKEMasterInfo.verify|verify} messages. + * Encodes the specified RedisInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisInstanceInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.IGKEMasterInfo} message GKEMasterInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRedisInstanceInfo} message RedisInstanceInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GKEMasterInfo.encodeDelimited = function encodeDelimited(message, writer) { + RedisInstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GKEMasterInfo message from the specified reader or buffer. + * Decodes a RedisInstanceInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisInstanceInfo} RedisInstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GKEMasterInfo.decode = function decode(reader, length) { + RedisInstanceInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } case 2: { - message.clusterUri = reader.string(); + message.uri = reader.string(); + break; + } + case 3: { + message.networkUri = reader.string(); break; } case 4: { - message.clusterNetworkUri = reader.string(); + message.primaryEndpointIp = reader.string(); break; } case 5: { - message.internalIp = reader.string(); + message.readEndpointIp = reader.string(); break; } case 6: { - message.externalIp = reader.string(); + message.region = reader.string(); break; } default: @@ -29159,152 +32058,168 @@ }; /** - * Decodes a GKEMasterInfo message from the specified reader or buffer, length delimited. + * Decodes a RedisInstanceInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisInstanceInfo} RedisInstanceInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GKEMasterInfo.decodeDelimited = function decodeDelimited(reader) { + RedisInstanceInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GKEMasterInfo message. + * Verifies a RedisInstanceInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GKEMasterInfo.verify = function verify(message) { + RedisInstanceInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.clusterUri != null && message.hasOwnProperty("clusterUri")) - if (!$util.isString(message.clusterUri)) - return "clusterUri: string expected"; - if (message.clusterNetworkUri != null && message.hasOwnProperty("clusterNetworkUri")) - if (!$util.isString(message.clusterNetworkUri)) - return "clusterNetworkUri: string expected"; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - if (!$util.isString(message.internalIp)) - return "internalIp: string expected"; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - if (!$util.isString(message.externalIp)) - return "externalIp: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.uri != null && message.hasOwnProperty("uri")) + if (!$util.isString(message.uri)) + return "uri: string expected"; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + if (!$util.isString(message.networkUri)) + return "networkUri: string expected"; + if (message.primaryEndpointIp != null && message.hasOwnProperty("primaryEndpointIp")) + if (!$util.isString(message.primaryEndpointIp)) + return "primaryEndpointIp: string expected"; + if (message.readEndpointIp != null && message.hasOwnProperty("readEndpointIp")) + if (!$util.isString(message.readEndpointIp)) + return "readEndpointIp: string expected"; + if (message.region != null && message.hasOwnProperty("region")) + if (!$util.isString(message.region)) + return "region: string expected"; return null; }; /** - * Creates a GKEMasterInfo message from a plain object. Also converts values to their respective internal types. + * Creates a RedisInstanceInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} GKEMasterInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisInstanceInfo} RedisInstanceInfo */ - GKEMasterInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo) + RedisInstanceInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.GKEMasterInfo(); - if (object.clusterUri != null) - message.clusterUri = String(object.clusterUri); - if (object.clusterNetworkUri != null) - message.clusterNetworkUri = String(object.clusterNetworkUri); - if (object.internalIp != null) - message.internalIp = String(object.internalIp); - if (object.externalIp != null) - message.externalIp = String(object.externalIp); + var message = new $root.google.cloud.networkmanagement.v1beta1.RedisInstanceInfo(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.uri != null) + message.uri = String(object.uri); + if (object.networkUri != null) + message.networkUri = String(object.networkUri); + if (object.primaryEndpointIp != null) + message.primaryEndpointIp = String(object.primaryEndpointIp); + if (object.readEndpointIp != null) + message.readEndpointIp = String(object.readEndpointIp); + if (object.region != null) + message.region = String(object.region); return message; }; /** - * Creates a plain object from a GKEMasterInfo message. Also converts values to other types if specified. + * Creates a plain object from a RedisInstanceInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.GKEMasterInfo} message GKEMasterInfo + * @param {google.cloud.networkmanagement.v1beta1.RedisInstanceInfo} message RedisInstanceInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GKEMasterInfo.toObject = function toObject(message, options) { + RedisInstanceInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.clusterUri = ""; - object.clusterNetworkUri = ""; - object.internalIp = ""; - object.externalIp = ""; + object.displayName = ""; + object.uri = ""; + object.networkUri = ""; + object.primaryEndpointIp = ""; + object.readEndpointIp = ""; + object.region = ""; } - if (message.clusterUri != null && message.hasOwnProperty("clusterUri")) - object.clusterUri = message.clusterUri; - if (message.clusterNetworkUri != null && message.hasOwnProperty("clusterNetworkUri")) - object.clusterNetworkUri = message.clusterNetworkUri; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - object.internalIp = message.internalIp; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - object.externalIp = message.externalIp; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.uri != null && message.hasOwnProperty("uri")) + object.uri = message.uri; + if (message.networkUri != null && message.hasOwnProperty("networkUri")) + object.networkUri = message.networkUri; + if (message.primaryEndpointIp != null && message.hasOwnProperty("primaryEndpointIp")) + object.primaryEndpointIp = message.primaryEndpointIp; + if (message.readEndpointIp != null && message.hasOwnProperty("readEndpointIp")) + object.readEndpointIp = message.readEndpointIp; + if (message.region != null && message.hasOwnProperty("region")) + object.region = message.region; return object; }; /** - * Converts this GKEMasterInfo to JSON. + * Converts this RedisInstanceInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @instance * @returns {Object.} JSON object */ - GKEMasterInfo.prototype.toJSON = function toJSON() { + RedisInstanceInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GKEMasterInfo + * Gets the default type url for RedisInstanceInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.GKEMasterInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisInstanceInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GKEMasterInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RedisInstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.GKEMasterInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.RedisInstanceInfo"; }; - return GKEMasterInfo; + return RedisInstanceInfo; })(); - v1beta1.CloudSQLInstanceInfo = (function() { + v1beta1.RedisClusterInfo = (function() { /** - * Properties of a CloudSQLInstanceInfo. + * Properties of a RedisClusterInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @interface ICloudSQLInstanceInfo - * @property {string|null} [displayName] CloudSQLInstanceInfo displayName - * @property {string|null} [uri] CloudSQLInstanceInfo uri - * @property {string|null} [networkUri] CloudSQLInstanceInfo networkUri - * @property {string|null} [internalIp] CloudSQLInstanceInfo internalIp - * @property {string|null} [externalIp] CloudSQLInstanceInfo externalIp - * @property {string|null} [region] CloudSQLInstanceInfo region + * @interface IRedisClusterInfo + * @property {string|null} [displayName] RedisClusterInfo displayName + * @property {string|null} [uri] RedisClusterInfo uri + * @property {string|null} [networkUri] RedisClusterInfo networkUri + * @property {string|null} [discoveryEndpointIpAddress] RedisClusterInfo discoveryEndpointIpAddress + * @property {string|null} [secondaryEndpointIpAddress] RedisClusterInfo secondaryEndpointIpAddress + * @property {string|null} [location] RedisClusterInfo location */ /** - * Constructs a new CloudSQLInstanceInfo. + * Constructs a new RedisClusterInfo. * @memberof google.cloud.networkmanagement.v1beta1 - * @classdesc Represents a CloudSQLInstanceInfo. - * @implements ICloudSQLInstanceInfo + * @classdesc Represents a RedisClusterInfo. + * @implements IRedisClusterInfo * @constructor - * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo=} [properties] Properties to set + * @param {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo=} [properties] Properties to set */ - function CloudSQLInstanceInfo(properties) { + function RedisClusterInfo(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -29312,75 +32227,75 @@ } /** - * CloudSQLInstanceInfo displayName. + * RedisClusterInfo displayName. * @member {string} displayName - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.displayName = ""; + RedisClusterInfo.prototype.displayName = ""; /** - * CloudSQLInstanceInfo uri. + * RedisClusterInfo uri. * @member {string} uri - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.uri = ""; + RedisClusterInfo.prototype.uri = ""; /** - * CloudSQLInstanceInfo networkUri. + * RedisClusterInfo networkUri. * @member {string} networkUri - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.networkUri = ""; + RedisClusterInfo.prototype.networkUri = ""; /** - * CloudSQLInstanceInfo internalIp. - * @member {string} internalIp - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * RedisClusterInfo discoveryEndpointIpAddress. + * @member {string} discoveryEndpointIpAddress + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.internalIp = ""; + RedisClusterInfo.prototype.discoveryEndpointIpAddress = ""; /** - * CloudSQLInstanceInfo externalIp. - * @member {string} externalIp - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * RedisClusterInfo secondaryEndpointIpAddress. + * @member {string} secondaryEndpointIpAddress + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.externalIp = ""; + RedisClusterInfo.prototype.secondaryEndpointIpAddress = ""; /** - * CloudSQLInstanceInfo region. - * @member {string} region - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * RedisClusterInfo location. + * @member {string} location + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance */ - CloudSQLInstanceInfo.prototype.region = ""; + RedisClusterInfo.prototype.location = ""; /** - * Creates a new CloudSQLInstanceInfo instance using the specified properties. + * Creates a new RedisClusterInfo instance using the specified properties. * @function create - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo=} [properties] Properties to set - * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo instance + * @param {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.RedisClusterInfo} RedisClusterInfo instance */ - CloudSQLInstanceInfo.create = function create(properties) { - return new CloudSQLInstanceInfo(properties); + RedisClusterInfo.create = function create(properties) { + return new RedisClusterInfo(properties); }; /** - * Encodes the specified CloudSQLInstanceInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify|verify} messages. + * Encodes the specified RedisClusterInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisClusterInfo.verify|verify} messages. * @function encode - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo} message CloudSQLInstanceInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo} message RedisClusterInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudSQLInstanceInfo.encode = function encode(message, writer) { + RedisClusterInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) @@ -29388,44 +32303,44 @@ if (message.uri != null && Object.hasOwnProperty.call(message, "uri")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.uri); if (message.networkUri != null && Object.hasOwnProperty.call(message, "networkUri")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.networkUri); - if (message.internalIp != null && Object.hasOwnProperty.call(message, "internalIp")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.internalIp); - if (message.externalIp != null && Object.hasOwnProperty.call(message, "externalIp")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.externalIp); - if (message.region != null && Object.hasOwnProperty.call(message, "region")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.region); + writer.uint32(/* id 3, wireType 2 =*/26).string(message.networkUri); + if (message.discoveryEndpointIpAddress != null && Object.hasOwnProperty.call(message, "discoveryEndpointIpAddress")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.discoveryEndpointIpAddress); + if (message.secondaryEndpointIpAddress != null && Object.hasOwnProperty.call(message, "secondaryEndpointIpAddress")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.secondaryEndpointIpAddress); + if (message.location != null && Object.hasOwnProperty.call(message, "location")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.location); return writer; }; /** - * Encodes the specified CloudSQLInstanceInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.verify|verify} messages. + * Encodes the specified RedisClusterInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.RedisClusterInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.ICloudSQLInstanceInfo} message CloudSQLInstanceInfo message or plain object to encode + * @param {google.cloud.networkmanagement.v1beta1.IRedisClusterInfo} message RedisClusterInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CloudSQLInstanceInfo.encodeDelimited = function encodeDelimited(message, writer) { + RedisClusterInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CloudSQLInstanceInfo message from the specified reader or buffer. + * Decodes a RedisClusterInfo message from the specified reader or buffer. * @function decode - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisClusterInfo} RedisClusterInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudSQLInstanceInfo.decode = function decode(reader, length) { + RedisClusterInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -29437,20 +32352,20 @@ message.uri = reader.string(); break; } - case 4: { + case 3: { message.networkUri = reader.string(); break; } - case 5: { - message.internalIp = reader.string(); + case 4: { + message.discoveryEndpointIpAddress = reader.string(); break; } - case 6: { - message.externalIp = reader.string(); + case 5: { + message.secondaryEndpointIpAddress = reader.string(); break; } - case 7: { - message.region = reader.string(); + case 6: { + message.location = reader.string(); break; } default: @@ -29462,30 +32377,30 @@ }; /** - * Decodes a CloudSQLInstanceInfo message from the specified reader or buffer, length delimited. + * Decodes a RedisClusterInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisClusterInfo} RedisClusterInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CloudSQLInstanceInfo.decodeDelimited = function decodeDelimited(reader) { + RedisClusterInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CloudSQLInstanceInfo message. + * Verifies a RedisClusterInfo message. * @function verify - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CloudSQLInstanceInfo.verify = function verify(message) { + RedisClusterInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) @@ -29497,55 +32412,55 @@ if (message.networkUri != null && message.hasOwnProperty("networkUri")) if (!$util.isString(message.networkUri)) return "networkUri: string expected"; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - if (!$util.isString(message.internalIp)) - return "internalIp: string expected"; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - if (!$util.isString(message.externalIp)) - return "externalIp: string expected"; - if (message.region != null && message.hasOwnProperty("region")) - if (!$util.isString(message.region)) - return "region: string expected"; + if (message.discoveryEndpointIpAddress != null && message.hasOwnProperty("discoveryEndpointIpAddress")) + if (!$util.isString(message.discoveryEndpointIpAddress)) + return "discoveryEndpointIpAddress: string expected"; + if (message.secondaryEndpointIpAddress != null && message.hasOwnProperty("secondaryEndpointIpAddress")) + if (!$util.isString(message.secondaryEndpointIpAddress)) + return "secondaryEndpointIpAddress: string expected"; + if (message.location != null && message.hasOwnProperty("location")) + if (!$util.isString(message.location)) + return "location: string expected"; return null; }; /** - * Creates a CloudSQLInstanceInfo message from a plain object. Also converts values to their respective internal types. + * Creates a RedisClusterInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static * @param {Object.} object Plain object - * @returns {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} CloudSQLInstanceInfo + * @returns {google.cloud.networkmanagement.v1beta1.RedisClusterInfo} RedisClusterInfo */ - CloudSQLInstanceInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo) + RedisClusterInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo) return object; - var message = new $root.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo(); + var message = new $root.google.cloud.networkmanagement.v1beta1.RedisClusterInfo(); if (object.displayName != null) message.displayName = String(object.displayName); if (object.uri != null) message.uri = String(object.uri); if (object.networkUri != null) message.networkUri = String(object.networkUri); - if (object.internalIp != null) - message.internalIp = String(object.internalIp); - if (object.externalIp != null) - message.externalIp = String(object.externalIp); - if (object.region != null) - message.region = String(object.region); + if (object.discoveryEndpointIpAddress != null) + message.discoveryEndpointIpAddress = String(object.discoveryEndpointIpAddress); + if (object.secondaryEndpointIpAddress != null) + message.secondaryEndpointIpAddress = String(object.secondaryEndpointIpAddress); + if (object.location != null) + message.location = String(object.location); return message; }; /** - * Creates a plain object from a CloudSQLInstanceInfo message. Also converts values to other types if specified. + * Creates a plain object from a RedisClusterInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static - * @param {google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo} message CloudSQLInstanceInfo + * @param {google.cloud.networkmanagement.v1beta1.RedisClusterInfo} message RedisClusterInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CloudSQLInstanceInfo.toObject = function toObject(message, options) { + RedisClusterInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -29553,9 +32468,9 @@ object.displayName = ""; object.uri = ""; object.networkUri = ""; - object.internalIp = ""; - object.externalIp = ""; - object.region = ""; + object.discoveryEndpointIpAddress = ""; + object.secondaryEndpointIpAddress = ""; + object.location = ""; } if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; @@ -29563,42 +32478,42 @@ object.uri = message.uri; if (message.networkUri != null && message.hasOwnProperty("networkUri")) object.networkUri = message.networkUri; - if (message.internalIp != null && message.hasOwnProperty("internalIp")) - object.internalIp = message.internalIp; - if (message.externalIp != null && message.hasOwnProperty("externalIp")) - object.externalIp = message.externalIp; - if (message.region != null && message.hasOwnProperty("region")) - object.region = message.region; + if (message.discoveryEndpointIpAddress != null && message.hasOwnProperty("discoveryEndpointIpAddress")) + object.discoveryEndpointIpAddress = message.discoveryEndpointIpAddress; + if (message.secondaryEndpointIpAddress != null && message.hasOwnProperty("secondaryEndpointIpAddress")) + object.secondaryEndpointIpAddress = message.secondaryEndpointIpAddress; + if (message.location != null && message.hasOwnProperty("location")) + object.location = message.location; return object; }; /** - * Converts this CloudSQLInstanceInfo to JSON. + * Converts this RedisClusterInfo to JSON. * @function toJSON - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @instance * @returns {Object.} JSON object */ - CloudSQLInstanceInfo.prototype.toJSON = function toJSON() { + RedisClusterInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CloudSQLInstanceInfo + * Gets the default type url for RedisClusterInfo * @function getTypeUrl - * @memberof google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo + * @memberof google.cloud.networkmanagement.v1beta1.RedisClusterInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CloudSQLInstanceInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RedisClusterInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo"; + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.RedisClusterInfo"; }; - return CloudSQLInstanceInfo; + return RedisClusterInfo; })(); v1beta1.CloudFunctionInfo = (function() { @@ -32352,6 +35267,209 @@ return StorageBucketInfo; })(); + v1beta1.ServerlessNegInfo = (function() { + + /** + * Properties of a ServerlessNegInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @interface IServerlessNegInfo + * @property {string|null} [negUri] ServerlessNegInfo negUri + */ + + /** + * Constructs a new ServerlessNegInfo. + * @memberof google.cloud.networkmanagement.v1beta1 + * @classdesc Represents a ServerlessNegInfo. + * @implements IServerlessNegInfo + * @constructor + * @param {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo=} [properties] Properties to set + */ + function ServerlessNegInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ServerlessNegInfo negUri. + * @member {string} negUri + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @instance + */ + ServerlessNegInfo.prototype.negUri = ""; + + /** + * Creates a new ServerlessNegInfo instance using the specified properties. + * @function create + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo=} [properties] Properties to set + * @returns {google.cloud.networkmanagement.v1beta1.ServerlessNegInfo} ServerlessNegInfo instance + */ + ServerlessNegInfo.create = function create(properties) { + return new ServerlessNegInfo(properties); + }; + + /** + * Encodes the specified ServerlessNegInfo message. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.verify|verify} messages. + * @function encode + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo} message ServerlessNegInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ServerlessNegInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.negUri != null && Object.hasOwnProperty.call(message, "negUri")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.negUri); + return writer; + }; + + /** + * Encodes the specified ServerlessNegInfo message, length delimited. Does not implicitly {@link google.cloud.networkmanagement.v1beta1.ServerlessNegInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.IServerlessNegInfo} message ServerlessNegInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ServerlessNegInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ServerlessNegInfo message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.networkmanagement.v1beta1.ServerlessNegInfo} ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ServerlessNegInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.negUri = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ServerlessNegInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.networkmanagement.v1beta1.ServerlessNegInfo} ServerlessNegInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ServerlessNegInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ServerlessNegInfo message. + * @function verify + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ServerlessNegInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.negUri != null && message.hasOwnProperty("negUri")) + if (!$util.isString(message.negUri)) + return "negUri: string expected"; + return null; + }; + + /** + * Creates a ServerlessNegInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.networkmanagement.v1beta1.ServerlessNegInfo} ServerlessNegInfo + */ + ServerlessNegInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo) + return object; + var message = new $root.google.cloud.networkmanagement.v1beta1.ServerlessNegInfo(); + if (object.negUri != null) + message.negUri = String(object.negUri); + return message; + }; + + /** + * Creates a plain object from a ServerlessNegInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {google.cloud.networkmanagement.v1beta1.ServerlessNegInfo} message ServerlessNegInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ServerlessNegInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.negUri = ""; + if (message.negUri != null && message.hasOwnProperty("negUri")) + object.negUri = message.negUri; + return object; + }; + + /** + * Converts this ServerlessNegInfo to JSON. + * @function toJSON + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @instance + * @returns {Object.} JSON object + */ + ServerlessNegInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ServerlessNegInfo + * @function getTypeUrl + * @memberof google.cloud.networkmanagement.v1beta1.ServerlessNegInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ServerlessNegInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.networkmanagement.v1beta1.ServerlessNegInfo"; + }; + + return ServerlessNegInfo; + })(); + v1beta1.ReachabilityService = (function() { /** diff --git a/packages/google-cloud-networkmanagement/protos/protos.json b/packages/google-cloud-networkmanagement/protos/protos.json index 9ec4541f023..76c87175237 100644 --- a/packages/google-cloud-networkmanagement/protos/protos.json +++ b/packages/google-cloud-networkmanagement/protos/protos.json @@ -1,4 +1,7 @@ { + "options": { + "syntax": "proto3" + }, "nested": { "google": { "nested": { @@ -27,7 +30,7 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "IDENTIFIER" } }, "description": { @@ -170,6 +173,14 @@ "type": "string", "id": 8 }, + "redisInstance": { + "type": "string", + "id": 17 + }, + "redisCluster": { + "type": "string", + "id": 18 + }, "cloudFunction": { "type": "CloudFunctionEndpoint", "id": 10 @@ -395,13 +406,16 @@ "network", "gkeMaster", "cloudSqlInstance", + "redisInstance", + "redisCluster", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", - "storageBucket" + "storageBucket", + "serverlessNeg" ] } }, @@ -493,6 +507,14 @@ "type": "CloudSQLInstanceInfo", "id": 19 }, + "redisInstance": { + "type": "RedisInstanceInfo", + "id": 30 + }, + "redisCluster": { + "type": "RedisClusterInfo", + "id": 31 + }, "cloudFunction": { "type": "CloudFunctionInfo", "id": 20 @@ -520,6 +542,10 @@ "storageBucket": { "type": "StorageBucketInfo", "id": 28 + }, + "serverlessNeg": { + "type": "ServerlessNegInfo", + "id": 29 } }, "nested": { @@ -540,11 +566,14 @@ "START_FROM_PRIVATE_NETWORK": 3, "START_FROM_GKE_MASTER": 21, "START_FROM_CLOUD_SQL_INSTANCE": 22, + "START_FROM_REDIS_INSTANCE": 32, + "START_FROM_REDIS_CLUSTER": 33, "START_FROM_CLOUD_FUNCTION": 23, "START_FROM_APP_ENGINE_VERSION": 25, "START_FROM_CLOUD_RUN_REVISION": 26, "START_FROM_STORAGE_BUCKET": 29, "START_FROM_PSC_PUBLISHED_SERVICE": 30, + "START_FROM_SERVERLESS_NEG": 31, "APPLY_INGRESS_FIREWALL_RULE": 4, "APPLY_EGRESS_FIREWALL_RULE": 5, "APPLY_ROUTE": 6, @@ -605,6 +634,10 @@ "options": { "deprecated": true } + }, + "pscNetworkAttachmentUri": { + "type": "string", + "id": 9 } } }, @@ -618,9 +651,17 @@ "type": "string", "id": 2 }, + "matchedSubnetUri": { + "type": "string", + "id": 5 + }, "matchedIpRange": { "type": "string", "id": 4 + }, + "region": { + "type": "string", + "id": 6 } } }, @@ -664,6 +705,10 @@ "type": "string", "id": 9 }, + "policyUri": { + "type": "string", + "id": 11 + }, "firewallRuleType": { "type": "FirewallRuleType", "id": 10 @@ -696,6 +741,16 @@ "oneof": [ "nccSpokeUri" ] + }, + "_advertisedRouteSourceRouterUri": { + "oneof": [ + "advertisedRouteSourceRouterUri" + ] + }, + "_advertisedRouteNextHopUri": { + "oneof": [ + "advertisedRouteNextHopUri" + ] } }, "fields": { @@ -719,6 +774,10 @@ "type": "string", "id": 2 }, + "region": { + "type": "string", + "id": 19 + }, "destIpRange": { "type": "string", "id": 3 @@ -772,6 +831,20 @@ "options": { "proto3_optional": true } + }, + "advertisedRouteSourceRouterUri": { + "type": "string", + "id": 17, + "options": { + "proto3_optional": true + } + }, + "advertisedRouteNextHopUri": { + "type": "string", + "id": 18, + "options": { + "proto3_optional": true + } } }, "nested": { @@ -784,7 +857,8 @@ "PEERING_SUBNET": 4, "PEERING_STATIC": 5, "PEERING_DYNAMIC": 6, - "POLICY_BASED": 7 + "POLICY_BASED": 7, + "ADVERTISED": 101 } }, "NextHopType": { @@ -867,6 +941,22 @@ "networkUri": { "type": "string", "id": 7 + }, + "region": { + "type": "string", + "id": 8 + }, + "loadBalancerName": { + "type": "string", + "id": 9 + }, + "pscServiceAttachmentUri": { + "type": "string", + "id": 10 + }, + "pscGoogleApiTarget": { + "type": "string", + "id": 11 } } }, @@ -1083,6 +1173,14 @@ "options": { "(google.api.field_info).format": "IPV4_OR_IPV6" } + }, + "storageBucket": { + "type": "string", + "id": 4 + }, + "pscGoogleApiTarget": { + "type": "string", + "id": 5 } }, "nested": { @@ -1102,7 +1200,10 @@ "PRIVATE_NETWORK": 11, "CLOUD_FUNCTION": 12, "APP_ENGINE_VERSION": 13, - "CLOUD_RUN_REVISION": 14 + "CLOUD_RUN_REVISION": 14, + "GOOGLE_MANAGED_SERVICE": 15, + "REDIS_INSTANCE": 16, + "REDIS_CLUSTER": 17 } } } @@ -1212,10 +1313,12 @@ "DESTINATION_ENDPOINT_NOT_FOUND": 13, "MISMATCHED_DESTINATION_NETWORK": 14, "UNKNOWN_IP": 2, + "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP": 32, "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK": 23, "PERMISSION_DENIED": 4, "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS": 28, "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS": 29, + "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS": 36, "NO_SOURCE_LOCATION": 5, "INVALID_ARGUMENT": 6, "TRACE_TOO_LONG": 9, @@ -1230,6 +1333,8 @@ "ROUTE_CONFIG_NOT_FOUND": 27, "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT": 19, "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED": 20, + "SOURCE_REDIS_CLUSTER_UNSUPPORTED": 34, + "SOURCE_REDIS_INSTANCE_UNSUPPORTED": 35, "SOURCE_FORWARDING_RULE_UNSUPPORTED": 21, "NON_ROUTABLE_IP_ADDRESS": 22, "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT": 30, @@ -1292,6 +1397,8 @@ "INSTANCE_NOT_RUNNING": 14, "GKE_CLUSTER_NOT_RUNNING": 27, "CLOUD_SQL_INSTANCE_NOT_RUNNING": 28, + "REDIS_INSTANCE_NOT_RUNNING": 68, + "REDIS_CLUSTER_NOT_RUNNING": 69, "TRAFFIC_TYPE_BLOCKED": 15, "GKE_MASTER_UNAUTHORIZED_ACCESS": 16, "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS": 17, @@ -1307,9 +1414,12 @@ "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC": 33, "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION": 34, "CLOUD_SQL_INSTANCE_NO_ROUTE": 35, + "CLOUD_SQL_CONNECTOR_REQUIRED": 63, "CLOUD_FUNCTION_NOT_ACTIVE": 22, "VPC_CONNECTOR_NOT_SET": 23, "VPC_CONNECTOR_NOT_RUNNING": 24, + "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED": 60, + "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED": 61, "FORWARDING_RULE_REGION_MISMATCH": 25, "PSC_CONNECTION_NOT_ACCEPTED": 26, "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK": 41, @@ -1317,13 +1427,31 @@ "PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS": 54, "CLOUD_SQL_PSC_NEG_UNSUPPORTED": 58, "NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT": 57, + "PSC_TRANSITIVITY_NOT_PROPAGATED": 64, "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED": 55, "HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED": 56, "CLOUD_RUN_REVISION_NOT_READY": 29, "DROPPED_INSIDE_PSC_SERVICE_PRODUCER": 37, "LOAD_BALANCER_HAS_NO_PROXY_SUBNET": 39, "CLOUD_NAT_NO_ADDRESSES": 40, - "ROUTING_LOOP": 59 + "ROUTING_LOOP": 59, + "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE": 62, + "LOAD_BALANCER_BACKEND_INVALID_NETWORK": 65, + "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED": 66, + "DESTINATION_IS_PRIVATE_NAT_IP_RANGE": 67, + "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE": 70, + "REDIS_INSTANCE_UNSUPPORTED_PORT": 71, + "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS": 72, + "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK": 73, + "REDIS_INSTANCE_NO_EXTERNAL_IP": 74, + "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL": 78, + "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE": 75, + "REDIS_CLUSTER_UNSUPPORTED_PORT": 76, + "REDIS_CLUSTER_NO_EXTERNAL_IP": 77, + "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL": 79, + "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION": 80, + "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION": 81, + "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION": 82 } } } @@ -1376,6 +1504,68 @@ } } }, + "RedisInstanceInfo": { + "fields": { + "displayName": { + "type": "string", + "id": 1 + }, + "uri": { + "type": "string", + "id": 2 + }, + "networkUri": { + "type": "string", + "id": 3 + }, + "primaryEndpointIp": { + "type": "string", + "id": 4 + }, + "readEndpointIp": { + "type": "string", + "id": 5 + }, + "region": { + "type": "string", + "id": 6 + } + } + }, + "RedisClusterInfo": { + "fields": { + "displayName": { + "type": "string", + "id": 1 + }, + "uri": { + "type": "string", + "id": 2 + }, + "networkUri": { + "type": "string", + "id": 3 + }, + "discoveryEndpointIpAddress": { + "type": "string", + "id": 4, + "options": { + "(google.api.field_info).format": "IPV4_OR_IPV6" + } + }, + "secondaryEndpointIpAddress": { + "type": "string", + "id": 5, + "options": { + "(google.api.field_info).format": "IPV4_OR_IPV6" + } + }, + "location": { + "type": "string", + "id": 6 + } + } + }, "CloudFunctionInfo": { "fields": { "displayName": { @@ -1648,6 +1838,14 @@ } } }, + "ServerlessNegInfo": { + "fields": { + "negUri": { + "type": "string", + "id": 1 + } + } + }, "ReachabilityService": { "options": { "(google.api.default_host)": "networkmanagement.googleapis.com", @@ -1804,7 +2002,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "cloudresourcemanager.googleapis.com/Project" } }, "pageSize": { @@ -1849,7 +2048,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } @@ -1860,7 +2060,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "cloudresourcemanager.googleapis.com/Project" } }, "testId": { @@ -1903,7 +2104,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } @@ -1914,7 +2116,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } @@ -1974,7 +2177,7 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "IDENTIFIER" } }, "description": { @@ -2117,6 +2320,14 @@ "type": "string", "id": 8 }, + "redisInstance": { + "type": "string", + "id": 17 + }, + "redisCluster": { + "type": "string", + "id": 18 + }, "cloudFunction": { "type": "CloudFunctionEndpoint", "id": 10 @@ -2342,13 +2553,16 @@ "network", "gkeMaster", "cloudSqlInstance", + "redisInstance", + "redisCluster", "cloudFunction", "appEngineVersion", "cloudRunRevision", "nat", "proxyConnection", "loadBalancerBackendInfo", - "storageBucket" + "storageBucket", + "serverlessNeg" ] } }, @@ -2440,6 +2654,14 @@ "type": "CloudSQLInstanceInfo", "id": 19 }, + "redisInstance": { + "type": "RedisInstanceInfo", + "id": 30 + }, + "redisCluster": { + "type": "RedisClusterInfo", + "id": 31 + }, "cloudFunction": { "type": "CloudFunctionInfo", "id": 20 @@ -2467,6 +2689,10 @@ "storageBucket": { "type": "StorageBucketInfo", "id": 28 + }, + "serverlessNeg": { + "type": "ServerlessNegInfo", + "id": 29 } }, "nested": { @@ -2487,11 +2713,14 @@ "START_FROM_PRIVATE_NETWORK": 3, "START_FROM_GKE_MASTER": 21, "START_FROM_CLOUD_SQL_INSTANCE": 22, + "START_FROM_REDIS_INSTANCE": 32, + "START_FROM_REDIS_CLUSTER": 33, "START_FROM_CLOUD_FUNCTION": 23, "START_FROM_APP_ENGINE_VERSION": 25, "START_FROM_CLOUD_RUN_REVISION": 26, "START_FROM_STORAGE_BUCKET": 29, "START_FROM_PSC_PUBLISHED_SERVICE": 30, + "START_FROM_SERVERLESS_NEG": 31, "APPLY_INGRESS_FIREWALL_RULE": 4, "APPLY_EGRESS_FIREWALL_RULE": 5, "APPLY_ROUTE": 6, @@ -2552,6 +2781,10 @@ "options": { "deprecated": true } + }, + "pscNetworkAttachmentUri": { + "type": "string", + "id": 9 } } }, @@ -2565,9 +2798,17 @@ "type": "string", "id": 2 }, + "matchedSubnetUri": { + "type": "string", + "id": 5 + }, "matchedIpRange": { "type": "string", "id": 4 + }, + "region": { + "type": "string", + "id": 6 } } }, @@ -2611,6 +2852,10 @@ "type": "string", "id": 9 }, + "policyUri": { + "type": "string", + "id": 11 + }, "firewallRuleType": { "type": "FirewallRuleType", "id": 10 @@ -2643,6 +2888,16 @@ "oneof": [ "nccSpokeUri" ] + }, + "_advertisedRouteSourceRouterUri": { + "oneof": [ + "advertisedRouteSourceRouterUri" + ] + }, + "_advertisedRouteNextHopUri": { + "oneof": [ + "advertisedRouteNextHopUri" + ] } }, "fields": { @@ -2666,6 +2921,10 @@ "type": "string", "id": 2 }, + "region": { + "type": "string", + "id": 19 + }, "destIpRange": { "type": "string", "id": 3 @@ -2719,6 +2978,20 @@ "options": { "proto3_optional": true } + }, + "advertisedRouteSourceRouterUri": { + "type": "string", + "id": 17, + "options": { + "proto3_optional": true + } + }, + "advertisedRouteNextHopUri": { + "type": "string", + "id": 18, + "options": { + "proto3_optional": true + } } }, "nested": { @@ -2731,7 +3004,8 @@ "PEERING_SUBNET": 4, "PEERING_STATIC": 5, "PEERING_DYNAMIC": 6, - "POLICY_BASED": 7 + "POLICY_BASED": 7, + "ADVERTISED": 101 } }, "NextHopType": { @@ -2814,6 +3088,22 @@ "networkUri": { "type": "string", "id": 7 + }, + "region": { + "type": "string", + "id": 8 + }, + "loadBalancerName": { + "type": "string", + "id": 9 + }, + "pscServiceAttachmentUri": { + "type": "string", + "id": 10 + }, + "pscGoogleApiTarget": { + "type": "string", + "id": 11 } } }, @@ -3030,6 +3320,14 @@ "options": { "(google.api.field_info).format": "IPV4_OR_IPV6" } + }, + "storageBucket": { + "type": "string", + "id": 4 + }, + "pscGoogleApiTarget": { + "type": "string", + "id": 5 } }, "nested": { @@ -3049,7 +3347,10 @@ "PRIVATE_NETWORK": 11, "CLOUD_FUNCTION": 12, "APP_ENGINE_VERSION": 13, - "CLOUD_RUN_REVISION": 14 + "CLOUD_RUN_REVISION": 14, + "GOOGLE_MANAGED_SERVICE": 15, + "REDIS_INSTANCE": 16, + "REDIS_CLUSTER": 17 } } } @@ -3159,10 +3460,12 @@ "DESTINATION_ENDPOINT_NOT_FOUND": 13, "MISMATCHED_DESTINATION_NETWORK": 14, "UNKNOWN_IP": 2, + "GOOGLE_MANAGED_SERVICE_UNKNOWN_IP": 32, "SOURCE_IP_ADDRESS_NOT_IN_SOURCE_NETWORK": 23, "PERMISSION_DENIED": 4, "PERMISSION_DENIED_NO_CLOUD_NAT_CONFIGS": 28, "PERMISSION_DENIED_NO_NEG_ENDPOINT_CONFIGS": 29, + "PERMISSION_DENIED_NO_CLOUD_ROUTER_CONFIGS": 36, "NO_SOURCE_LOCATION": 5, "INVALID_ARGUMENT": 6, "TRACE_TOO_LONG": 9, @@ -3177,6 +3480,8 @@ "ROUTE_CONFIG_NOT_FOUND": 27, "GOOGLE_MANAGED_SERVICE_AMBIGUOUS_PSC_ENDPOINT": 19, "SOURCE_PSC_CLOUD_SQL_UNSUPPORTED": 20, + "SOURCE_REDIS_CLUSTER_UNSUPPORTED": 34, + "SOURCE_REDIS_INSTANCE_UNSUPPORTED": 35, "SOURCE_FORWARDING_RULE_UNSUPPORTED": 21, "NON_ROUTABLE_IP_ADDRESS": 22, "UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT": 30, @@ -3239,6 +3544,8 @@ "INSTANCE_NOT_RUNNING": 14, "GKE_CLUSTER_NOT_RUNNING": 27, "CLOUD_SQL_INSTANCE_NOT_RUNNING": 28, + "REDIS_INSTANCE_NOT_RUNNING": 68, + "REDIS_CLUSTER_NOT_RUNNING": 69, "TRAFFIC_TYPE_BLOCKED": 15, "GKE_MASTER_UNAUTHORIZED_ACCESS": 16, "CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS": 17, @@ -3254,9 +3561,12 @@ "CLOUD_SQL_INSTANCE_NOT_CONFIGURED_FOR_EXTERNAL_TRAFFIC": 33, "PUBLIC_CLOUD_SQL_INSTANCE_TO_PRIVATE_DESTINATION": 34, "CLOUD_SQL_INSTANCE_NO_ROUTE": 35, + "CLOUD_SQL_CONNECTOR_REQUIRED": 63, "CLOUD_FUNCTION_NOT_ACTIVE": 22, "VPC_CONNECTOR_NOT_SET": 23, "VPC_CONNECTOR_NOT_RUNNING": 24, + "VPC_CONNECTOR_SERVERLESS_TRAFFIC_BLOCKED": 60, + "VPC_CONNECTOR_HEALTH_CHECK_TRAFFIC_BLOCKED": 61, "FORWARDING_RULE_REGION_MISMATCH": 25, "PSC_CONNECTION_NOT_ACCEPTED": 26, "PSC_ENDPOINT_ACCESSED_FROM_PEERED_NETWORK": 41, @@ -3264,13 +3574,31 @@ "PSC_NEG_PRODUCER_FORWARDING_RULE_MULTIPLE_PORTS": 54, "CLOUD_SQL_PSC_NEG_UNSUPPORTED": 58, "NO_NAT_SUBNETS_FOR_PSC_SERVICE_ATTACHMENT": 57, + "PSC_TRANSITIVITY_NOT_PROPAGATED": 64, "HYBRID_NEG_NON_DYNAMIC_ROUTE_MATCHED": 55, "HYBRID_NEG_NON_LOCAL_DYNAMIC_ROUTE_MATCHED": 56, "CLOUD_RUN_REVISION_NOT_READY": 29, "DROPPED_INSIDE_PSC_SERVICE_PRODUCER": 37, "LOAD_BALANCER_HAS_NO_PROXY_SUBNET": 39, "CLOUD_NAT_NO_ADDRESSES": 40, - "ROUTING_LOOP": 59 + "ROUTING_LOOP": 59, + "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE": 62, + "LOAD_BALANCER_BACKEND_INVALID_NETWORK": 65, + "BACKEND_SERVICE_NAMED_PORT_NOT_DEFINED": 66, + "DESTINATION_IS_PRIVATE_NAT_IP_RANGE": 67, + "DROPPED_INSIDE_REDIS_INSTANCE_SERVICE": 70, + "REDIS_INSTANCE_UNSUPPORTED_PORT": 71, + "REDIS_INSTANCE_CONNECTING_FROM_PUPI_ADDRESS": 72, + "REDIS_INSTANCE_NO_ROUTE_TO_DESTINATION_NETWORK": 73, + "REDIS_INSTANCE_NO_EXTERNAL_IP": 74, + "REDIS_INSTANCE_UNSUPPORTED_PROTOCOL": 78, + "DROPPED_INSIDE_REDIS_CLUSTER_SERVICE": 75, + "REDIS_CLUSTER_UNSUPPORTED_PORT": 76, + "REDIS_CLUSTER_NO_EXTERNAL_IP": 77, + "REDIS_CLUSTER_UNSUPPORTED_PROTOCOL": 79, + "NO_ADVERTISED_ROUTE_TO_GCP_DESTINATION": 80, + "NO_TRAFFIC_SELECTOR_TO_GCP_DESTINATION": 81, + "NO_KNOWN_ROUTE_FROM_PEERED_NETWORK_TO_DESTINATION": 82 } } } @@ -3323,6 +3651,68 @@ } } }, + "RedisInstanceInfo": { + "fields": { + "displayName": { + "type": "string", + "id": 1 + }, + "uri": { + "type": "string", + "id": 2 + }, + "networkUri": { + "type": "string", + "id": 3 + }, + "primaryEndpointIp": { + "type": "string", + "id": 4 + }, + "readEndpointIp": { + "type": "string", + "id": 5 + }, + "region": { + "type": "string", + "id": 6 + } + } + }, + "RedisClusterInfo": { + "fields": { + "displayName": { + "type": "string", + "id": 1 + }, + "uri": { + "type": "string", + "id": 2 + }, + "networkUri": { + "type": "string", + "id": 3 + }, + "discoveryEndpointIpAddress": { + "type": "string", + "id": 4, + "options": { + "(google.api.field_info).format": "IPV4_OR_IPV6" + } + }, + "secondaryEndpointIpAddress": { + "type": "string", + "id": 5, + "options": { + "(google.api.field_info).format": "IPV4_OR_IPV6" + } + }, + "location": { + "type": "string", + "id": 6 + } + } + }, "CloudFunctionInfo": { "fields": { "displayName": { @@ -3595,6 +3985,14 @@ } } }, + "ServerlessNegInfo": { + "fields": { + "negUri": { + "type": "string", + "id": 1 + } + } + }, "ReachabilityService": { "options": { "(google.api.default_host)": "networkmanagement.googleapis.com", @@ -3731,7 +4129,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "cloudresourcemanager.googleapis.com/Project" } }, "pageSize": { @@ -3776,7 +4175,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } @@ -3787,7 +4187,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "cloudresourcemanager.googleapis.com/Project" } }, "testId": { @@ -3830,7 +4231,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } @@ -3841,7 +4243,8 @@ "type": "string", "id": 1, "options": { - "(google.api.field_behavior)": "REQUIRED" + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "networkmanagement.googleapis.com/ConnectivityTest" } } } diff --git a/packages/google-cloud-networkmanagement/samples/generated/v1/snippet_metadata_google.cloud.networkmanagement.v1.json b/packages/google-cloud-networkmanagement/samples/generated/v1/snippet_metadata_google.cloud.networkmanagement.v1.json index 481c4260b7c..35f65c3fc04 100644 --- a/packages/google-cloud-networkmanagement/samples/generated/v1/snippet_metadata_google.cloud.networkmanagement.v1.json +++ b/packages/google-cloud-networkmanagement/samples/generated/v1/snippet_metadata_google.cloud.networkmanagement.v1.json @@ -159,7 +159,7 @@ "regionTag": "networkmanagement_v1_generated_ReachabilityService_UpdateConnectivityTest_async", "title": "ReachabilityService updateConnectivityTest Sample", "origin": "API_DEFINITION", - "description": " Updates the configuration of an existing `ConnectivityTest`. After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in `ConnectivityTest` are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in `ConnectivityTest` are incomplete, the reachability result returns a value of `AMBIGUOUS`. See the documentation in `ConnectivityTest` for for more details.", + "description": " Updates the configuration of an existing `ConnectivityTest`. After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in `ConnectivityTest` are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in `ConnectivityTest` are incomplete, the reachability result returns a value of `AMBIGUOUS`. See the documentation in `ConnectivityTest` for more details.", "canonical": true, "file": "reachability_service.update_connectivity_test.js", "language": "JAVASCRIPT", diff --git a/packages/google-cloud-networkmanagement/samples/generated/v1beta1/snippet_metadata_google.cloud.networkmanagement.v1beta1.json b/packages/google-cloud-networkmanagement/samples/generated/v1beta1/snippet_metadata_google.cloud.networkmanagement.v1beta1.json index cc5d2eeb096..6fbd8d527e3 100644 --- a/packages/google-cloud-networkmanagement/samples/generated/v1beta1/snippet_metadata_google.cloud.networkmanagement.v1beta1.json +++ b/packages/google-cloud-networkmanagement/samples/generated/v1beta1/snippet_metadata_google.cloud.networkmanagement.v1beta1.json @@ -159,7 +159,7 @@ "regionTag": "networkmanagement_v1beta1_generated_ReachabilityService_UpdateConnectivityTest_async", "title": "ReachabilityService updateConnectivityTest Sample", "origin": "API_DEFINITION", - "description": " Updates the configuration of an existing `ConnectivityTest`. After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in `ConnectivityTest` are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in `ConnectivityTest` are incomplete, the reachability result returns a value of `AMBIGUOUS`. See the documentation in `ConnectivityTest` for for more details.", + "description": " Updates the configuration of an existing `ConnectivityTest`. After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in `ConnectivityTest` are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in `ConnectivityTest` are incomplete, the reachability result returns a value of `AMBIGUOUS`. See the documentation in `ConnectivityTest` for more details.", "canonical": true, "file": "reachability_service.update_connectivity_test.js", "language": "JAVASCRIPT", diff --git a/packages/google-cloud-networkmanagement/src/v1/reachability_service_client.ts b/packages/google-cloud-networkmanagement/src/v1/reachability_service_client.ts index d532db949d8..4f98241b5f4 100644 --- a/packages/google-cloud-networkmanagement/src/v1/reachability_service_client.ts +++ b/packages/google-cloud-networkmanagement/src/v1/reachability_service_client.ts @@ -224,6 +224,9 @@ export class ReachabilityServiceClient { connectivityTestPathTemplate: new this._gaxModule.PathTemplate( 'projects/{project}/locations/global/connectivityTests/{test}' ), + projectPathTemplate: new this._gaxModule.PathTemplate( + 'projects/{project}' + ), }; // Some of the methods on this service return "paged" results, @@ -804,7 +807,7 @@ export class ReachabilityServiceClient { * * If the endpoint specifications in `ConnectivityTest` are incomplete, the * reachability result returns a value of `AMBIGUOUS`. See the documentation - * in `ConnectivityTest` for for more details. + * in `ConnectivityTest` for more details. * * @param {Object} request * The request object that will be sent. @@ -1922,6 +1925,29 @@ export class ReachabilityServiceClient { ).test; } + /** + * Return a fully-qualified project resource name string. + * + * @param {string} project + * @returns {string} Resource name string. + */ + projectPath(project: string) { + return this.pathTemplates.projectPathTemplate.render({ + project: project, + }); + } + + /** + * Parse the project from Project resource. + * + * @param {string} projectName + * A fully-qualified path representing Project resource. + * @returns {string} A string representing the project. + */ + matchProjectFromProjectName(projectName: string) { + return this.pathTemplates.projectPathTemplate.match(projectName).project; + } + /** * Terminate the gRPC channel and close the client. * diff --git a/packages/google-cloud-networkmanagement/src/v1beta1/reachability_service_client.ts b/packages/google-cloud-networkmanagement/src/v1beta1/reachability_service_client.ts index f7fefa727e6..40b04078d43 100644 --- a/packages/google-cloud-networkmanagement/src/v1beta1/reachability_service_client.ts +++ b/packages/google-cloud-networkmanagement/src/v1beta1/reachability_service_client.ts @@ -224,6 +224,9 @@ export class ReachabilityServiceClient { connectivityTestPathTemplate: new this._gaxModule.PathTemplate( 'projects/{project}/locations/global/connectivityTests/{test}' ), + projectPathTemplate: new this._gaxModule.PathTemplate( + 'projects/{project}' + ), vpcFlowLogsConfigPathTemplate: new this._gaxModule.PathTemplate( 'projects/{project}/locations/{location}/vpcFlowLogsConfigs/{vpc_flow_logs_config}' ), @@ -807,7 +810,7 @@ export class ReachabilityServiceClient { * * If the endpoint specifications in `ConnectivityTest` are incomplete, the * reachability result returns a value of `AMBIGUOUS`. See the documentation - * in `ConnectivityTest` for for more details. + * in `ConnectivityTest` for more details. * * @param {Object} request * The request object that will be sent. @@ -1925,6 +1928,29 @@ export class ReachabilityServiceClient { ).test; } + /** + * Return a fully-qualified project resource name string. + * + * @param {string} project + * @returns {string} Resource name string. + */ + projectPath(project: string) { + return this.pathTemplates.projectPathTemplate.render({ + project: project, + }); + } + + /** + * Parse the project from Project resource. + * + * @param {string} projectName + * A fully-qualified path representing Project resource. + * @returns {string} A string representing the project. + */ + matchProjectFromProjectName(projectName: string) { + return this.pathTemplates.projectPathTemplate.match(projectName).project; + } + /** * Return a fully-qualified vpcFlowLogsConfig resource name string. * diff --git a/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1.ts b/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1.ts index b782406f538..07fb11a6b89 100644 --- a/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1.ts +++ b/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1.ts @@ -2646,5 +2646,45 @@ describe('v1.ReachabilityServiceClient', () => { ); }); }); + + describe('project', () => { + const fakePath = '/rendered/path/project'; + const expectedParameters = { + project: 'projectValue', + }; + const client = new reachabilityserviceModule.v1.ReachabilityServiceClient( + { + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + } + ); + client.initialize(); + client.pathTemplates.projectPathTemplate.render = sinon + .stub() + .returns(fakePath); + client.pathTemplates.projectPathTemplate.match = sinon + .stub() + .returns(expectedParameters); + + it('projectPath', () => { + const result = client.projectPath('projectValue'); + assert.strictEqual(result, fakePath); + assert( + (client.pathTemplates.projectPathTemplate.render as SinonStub) + .getCall(-1) + .calledWith(expectedParameters) + ); + }); + + it('matchProjectFromProjectName', () => { + const result = client.matchProjectFromProjectName(fakePath); + assert.strictEqual(result, 'projectValue'); + assert( + (client.pathTemplates.projectPathTemplate.match as SinonStub) + .getCall(-1) + .calledWith(fakePath) + ); + }); + }); }); }); diff --git a/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1beta1.ts b/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1beta1.ts index f7314d8a170..66c35cbd383 100644 --- a/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1beta1.ts +++ b/packages/google-cloud-networkmanagement/test/gapic_reachability_service_v1beta1.ts @@ -2585,6 +2585,45 @@ describe('v1beta1.ReachabilityServiceClient', () => { }); }); + describe('project', () => { + const fakePath = '/rendered/path/project'; + const expectedParameters = { + project: 'projectValue', + }; + const client = + new reachabilityserviceModule.v1beta1.ReachabilityServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + client.pathTemplates.projectPathTemplate.render = sinon + .stub() + .returns(fakePath); + client.pathTemplates.projectPathTemplate.match = sinon + .stub() + .returns(expectedParameters); + + it('projectPath', () => { + const result = client.projectPath('projectValue'); + assert.strictEqual(result, fakePath); + assert( + (client.pathTemplates.projectPathTemplate.render as SinonStub) + .getCall(-1) + .calledWith(expectedParameters) + ); + }); + + it('matchProjectFromProjectName', () => { + const result = client.matchProjectFromProjectName(fakePath); + assert.strictEqual(result, 'projectValue'); + assert( + (client.pathTemplates.projectPathTemplate.match as SinonStub) + .getCall(-1) + .calledWith(fakePath) + ); + }); + }); + describe('vpcFlowLogsConfig', () => { const fakePath = '/rendered/path/vpcFlowLogsConfig'; const expectedParameters = {