From 76a9e47ea7a751c29a3d65846c43735fe09f86b9 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 5 Mar 2026 17:58:11 +0000 Subject: [PATCH 1/2] feat: Add `OFFLINE` state to Zone resources A new `OFFLINE` state has been added to the `Zone.State` enum. This state indicates that the zone is temporarily not operational, for example, while undergoing maintenance or repair PiperOrigin-RevId: 879057351 Source-Link: https://github.com/googleapis/googleapis/commit/40a49dc1a2305fecb768414c6837b65d3ea8b809 Source-Link: https://github.com/googleapis/googleapis-gen/commit/77daef772d6cb525e73509d99da77c54c86cb597 Copy-Tag: eyJwIjoiZ29vZ2xlLWNsb3VkLWdkY19oYXJkd2FyZV9tYW5hZ2VtZW50LXYxYWxwaGEvLk93bEJvdC55YW1sIiwiaCI6Ijc3ZGFlZjc3MmQ2Y2I1MjVlNzM1MDlkOTlkYTc3YzU0Yzg2Y2I1OTcifQ== --- .../.gitignore | 22 + .../.repo-metadata.json | 18 + .../.rubocop.yml | 33 + .../.toys.rb | 28 + .../.yardopts | 12 + .../AUTHENTICATION.md | 122 + .../CHANGELOG.md | 2 + .../Gemfile | 11 + .../LICENSE.md | 201 + .../README.md | 154 + .../Rakefile | 169 + .../gapic_metadata.json | 203 + ...ud-gdc_hardware_management-v1alpha.gemspec | 29 + ...e-cloud-gdc_hardware_management-v1alpha.rb | 21 + .../cloud/gdc_hardware_management/v1alpha.rb | 45 + .../v1alpha/bindings_override.rb | 75 + .../v1alpha/gdc_hardware_management.rb | 56 + .../v1alpha/gdc_hardware_management/client.rb | 4499 +++++++++++++++++ .../gdc_hardware_management/credentials.rb | 47 + .../gdc_hardware_management/operations.rb | 841 +++ .../v1alpha/gdc_hardware_management/paths.rb | 208 + .../v1alpha/gdc_hardware_management/rest.rb | 54 + .../gdc_hardware_management/rest/client.rb | 4205 +++++++++++++++ .../rest/operations.rb | 925 ++++ .../rest/service_stub.rb | 2354 +++++++++ .../gdc_hardware_management/v1alpha/rest.rb | 38 + .../v1alpha/version.rb | 28 + .../v1alpha/resources_pb.rb | 99 + .../v1alpha/service_pb.rb | 107 + .../v1alpha/service_services_pb.rb | 120 + .../proto_docs/README.md | 4 + .../proto_docs/google/api/client.rb | 473 ++ .../proto_docs/google/api/field_behavior.rb | 85 + .../proto_docs/google/api/field_info.rb | 88 + .../proto_docs/google/api/launch_stage.rb | 71 + .../proto_docs/google/api/resource.rb | 227 + .../v1alpha/resources.rb | 1209 +++++ .../gdchardwaremanagement/v1alpha/service.rb | 959 ++++ .../google/longrunning/operations.rb | 191 + .../proto_docs/google/protobuf/any.rb | 145 + .../proto_docs/google/protobuf/duration.rb | 98 + .../proto_docs/google/protobuf/empty.rb | 34 + .../proto_docs/google/protobuf/field_mask.rb | 229 + .../proto_docs/google/protobuf/timestamp.rb | 127 + .../proto_docs/google/rpc/status.rb | 48 + .../proto_docs/google/type/date.rb | 53 + .../proto_docs/google/type/datetime.rb | 103 + .../proto_docs/google/type/dayofweek.rb | 49 + .../proto_docs/google/type/postal_address.rb | 135 + .../proto_docs/google/type/timeofday.rb | 45 + .../snippets/Gemfile | 32 + .../gdc_hardware_management/cancel_order.rb | 54 + .../gdc_hardware_management/create_comment.rb | 54 + .../create_hardware.rb | 54 + .../create_hardware_group.rb | 54 + .../gdc_hardware_management/create_order.rb | 54 + .../gdc_hardware_management/create_site.rb | 54 + .../gdc_hardware_management/create_zone.rb | 54 + .../delete_hardware.rb | 54 + .../delete_hardware_group.rb | 54 + .../gdc_hardware_management/delete_order.rb | 54 + .../gdc_hardware_management/delete_site.rb | 54 + .../gdc_hardware_management/delete_zone.rb | 54 + .../get_change_log_entry.rb | 47 + .../gdc_hardware_management/get_comment.rb | 47 + .../gdc_hardware_management/get_hardware.rb | 47 + .../get_hardware_group.rb | 47 + .../gdc_hardware_management/get_order.rb | 47 + .../gdc_hardware_management/get_site.rb | 47 + .../gdc_hardware_management/get_sku.rb | 47 + .../gdc_hardware_management/get_zone.rb | 47 + .../list_change_log_entries.rb | 51 + .../gdc_hardware_management/list_comments.rb | 51 + .../gdc_hardware_management/list_hardware.rb | 51 + .../list_hardware_groups.rb | 51 + .../gdc_hardware_management/list_orders.rb | 51 + .../gdc_hardware_management/list_sites.rb | 51 + .../gdc_hardware_management/list_skus.rb | 51 + .../gdc_hardware_management/list_zones.rb | 51 + .../record_action_on_comment.rb | 47 + .../request_order_date_change.rb | 54 + .../signal_zone_state.rb | 54 + .../gdc_hardware_management/submit_order.rb | 54 + .../update_hardware.rb | 54 + .../update_hardware_group.rb | 54 + .../gdc_hardware_management/update_order.rb | 54 + .../gdc_hardware_management/update_site.rb | 54 + .../gdc_hardware_management/update_zone.rb | 54 + ...e.cloud.gdchardwaremanagement.v1alpha.json | 1495 ++++++ ...gdc_hardware_management_operations_test.rb | 400 ++ .../gdc_hardware_management_paths_test.rb | 151 + .../gdc_hardware_management_rest_test.rb | 2172 ++++++++ .../v1alpha/gdc_hardware_management_test.rb | 2554 ++++++++++ .../test/helper.rb | 25 + 94 files changed, 27839 insertions(+) create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb create mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore new file mode 100644 index 000000000000..0135b6bc6cfc --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore @@ -0,0 +1,22 @@ +# Ignore bundler lockfiles +Gemfile.lock +gems.locked + +# Ignore documentation output +doc/* +.yardoc/* + +# Ignore test output +coverage/* + +# Ignore build artifacts +pkg/* + +# Ignore files commonly present in certain dev environments +.vagrant +.DS_STORE +.idea +*.iml + +# Ignore synth output +__pycache__ diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json new file mode 100644 index 000000000000..d9135f143ae9 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json @@ -0,0 +1,18 @@ +{ + "api_id": "gdchardwaremanagement.googleapis.com", + "api_shortname": "gdchardwaremanagement", + "client_documentation": "https://cloud.google.com/ruby/docs/reference/google-cloud-gdc_hardware_management-v1alpha/latest", + "distribution_name": "google-cloud-gdc_hardware_management-v1alpha", + "is_cloud": true, + "language": "ruby", + "name": "gdchardwaremanagement", + "name_pretty": "GDC Hardware Management V1ALPHA API", + "product_documentation": "https://cloud.google.com/distributed-cloud/edge/latest/docs", + "release_level": "unreleased", + "repo": "googleapis/google-cloud-ruby", + "requires_billing": true, + "ruby-cloud-description": "google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. Note that google-cloud-gdc_hardware_management-v1alpha is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-gdc_hardware_management instead. See the readme for more details.", + "ruby-cloud-product-url": "https://cloud.google.com/distributed-cloud/edge/latest/docs", + "ruby-cloud-service-override": "GdcHardwareManagement=GDCHardwareManagement", + "library_type": "GAPIC_AUTO" +} diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml new file mode 100644 index 000000000000..7c5bd6fa2fa0 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml @@ -0,0 +1,33 @@ +inherit_gem: + google-style: google-style.yml + +AllCops: + Exclude: + - "google-cloud-gdc_hardware_management-v1alpha.gemspec" + - "lib/**/*_pb.rb" + - "proto_docs/**/*" + - "test/**/*" + - "acceptance/**/*" + - "samples/acceptance/**/*" + - "Rakefile" + +Layout/LineLength: + Enabled: false +Metrics/AbcSize: + Enabled: false +Metrics/ClassLength: + Enabled: false +Metrics/CyclomaticComplexity: + Enabled: false +Metrics/MethodLength: + Enabled: false +Metrics/ModuleLength: + Enabled: false +Metrics/PerceivedComplexity: + Enabled: false +Naming/AccessorMethodName: + Exclude: + - "snippets/**/*.rb" +Naming/FileName: + Exclude: + - "lib/google-cloud-gdc_hardware_management-v1alpha.rb" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb new file mode 100644 index 000000000000..177e22456e8a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb @@ -0,0 +1,28 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +toys_version! ">= 0.15.3" + +if ENV["RUBY_COMMON_TOOLS"] + common_tools_dir = File.expand_path ENV["RUBY_COMMON_TOOLS"] + load File.join(common_tools_dir, "toys", "gapic") +else + load_git remote: "https://github.com/googleapis/ruby-common-tools.git", + path: "toys/gapic", + update: true +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts new file mode 100644 index 000000000000..eda2091db73f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts @@ -0,0 +1,12 @@ +--no-private +--title="GDC Hardware Management V1ALPHA API" +--exclude _pb\.rb$ +--markup markdown +--markup-provider redcarpet + +./lib/**/*.rb +./proto_docs/**/*.rb +- +README.md +LICENSE.md +AUTHENTICATION.md diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md new file mode 100644 index 000000000000..870900569f1a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md @@ -0,0 +1,122 @@ +# Authentication + +The recommended way to authenticate to the google-cloud-gdc_hardware_management-v1alpha library is to use +[Application Default Credentials (ADC)](https://cloud.google.com/docs/authentication/application-default-credentials). +To review all of your authentication options, see [Credentials lookup](#credential-lookup). + +## Quickstart + +The following example shows how to set up authentication for a local development +environment with your user credentials. + +**NOTE:** This method is _not_ recommended for running in production. User credentials +should be used only during development. + +1. [Download and install the Google Cloud CLI](https://cloud.google.com/sdk). +2. Set up a local ADC file with your user credentials: + +```sh +gcloud auth application-default login +``` + +3. Write code as if already authenticated. + +For more information about setting up authentication for a local development environment, see +[Set up Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-dev). + +## Credential Lookup + +The google-cloud-gdc_hardware_management-v1alpha library provides several mechanisms to configure your system. +Generally, using Application Default Credentials to facilitate automatic +credentials discovery is the easist method. But if you need to explicitly specify +credentials, there are several methods available to you. + +Credentials are accepted in the following ways, in the following order or precedence: + +1. Credentials specified in method arguments +2. Credentials specified in configuration +3. Credentials pointed to or included in environment variables +4. Credentials found in local ADC file +5. Credentials returned by the metadata server for the attached service account (GCP) + +### Configuration + +You can configure a path to a JSON credentials file, either for an individual client object or +globally, for all client objects. The JSON file can contain credentials created for +[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), +[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a +[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). + +Note: Service account keys are a security risk if not managed correctly. You should +[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) +whenever possible. + +To configure a credentials file for an individual client initialization: + +```ruby +require "google/cloud/gdc_hardware_management/v1alpha" + +client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = "path/to/credentialfile.json" +end +``` + +To configure a credentials file globally for all clients: + +```ruby +require "google/cloud/gdc_hardware_management/v1alpha" + +::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| + config.credentials = "path/to/credentialfile.json" +end + +client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new +``` + +### Environment Variables + +You can also use an environment variable to provide a JSON credentials file. +The environment variable can contain a path to the credentials file or, for +environments such as Docker containers where writing files is not encouraged, +you can include the credentials file itself. + +The JSON file can contain credentials created for +[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), +[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a +[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). + +Note: Service account keys are a security risk if not managed correctly. You should +[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) +whenever possible. + +The environment variables that google-cloud-gdc_hardware_management-v1alpha +checks for credentials are: + +* `GOOGLE_CLOUD_CREDENTIALS` - Path to JSON file, or JSON contents +* `GOOGLE_APPLICATION_CREDENTIALS` - Path to JSON file + +```ruby +require "google/cloud/gdc_hardware_management/v1alpha" + +ENV["GOOGLE_APPLICATION_CREDENTIALS"] = "path/to/credentialfile.json" + +client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new +``` + +### Local ADC file + +You can set up a local ADC file with your user credentials for authentication during +development. If credentials are not provided in code or in environment variables, +then the local ADC credentials are discovered. + +Follow the steps in [Quickstart](#quickstart) to set up a local ADC file. + +### Google Cloud Platform environments + +When running on Google Cloud Platform (GCP), including Google Compute Engine +(GCE), Google Kubernetes Engine (GKE), Google App Engine (GAE), Google Cloud +Functions (GCF) and Cloud Run, credentials are retrieved from the attached +service account automatically. Code should be written as if already authenticated. + +For more information, see +[Set up ADC for Google Cloud services](https://cloud.google.com/docs/authentication/provide-credentials-adc#attached-sa). diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md new file mode 100644 index 000000000000..f88957a62ba2 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md @@ -0,0 +1,2 @@ +# Release History + diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile new file mode 100644 index 000000000000..6442df18fa2f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile @@ -0,0 +1,11 @@ +source "https://rubygems.org" + +gemspec + +gem "google-style", "~> 1.31.1" +gem "minitest", "~> 5.22" +gem "minitest-focus", "~> 1.4" +gem "minitest-rg", "~> 5.3" +gem "rake", ">= 13.0" +gem "redcarpet", "~> 3.6" +gem "yard", "~> 0.9" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md new file mode 100644 index 000000000000..c261857ba6ad --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md new file mode 100644 index 000000000000..ef5d1772230c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md @@ -0,0 +1,154 @@ +# Ruby Client for the GDC Hardware Management V1ALPHA API + +API Client library for the GDC Hardware Management V1ALPHA API + +google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. + +https://github.com/googleapis/google-cloud-ruby + +This gem is a _versioned_ client. It provides basic client classes for a +specific version of the GDC Hardware Management V1ALPHA API. Most users should consider using +the main client gem, +[google-cloud-gdc_hardware_management](https://rubygems.org/gems/google-cloud-gdc_hardware_management). +See the section below titled *Which client should I use?* for more information. + +## Installation + +``` +$ gem install google-cloud-gdc_hardware_management-v1alpha +``` + +## Before You Begin + +In order to use this library, you first need to go through the following steps: + +1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project) +1. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project) +1. [Enable the API.](https://console.cloud.google.com/apis/library/gdchardwaremanagement.googleapis.com) +1. [Set up authentication.](AUTHENTICATION.md) + +## Quick Start + +```ruby +require "google/cloud/gdc_hardware_management/v1alpha" + +client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new +request = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new # (request fields as keyword arguments...) +response = client.list_orders request +``` + +View the [Client Library Documentation](https://cloud.google.com/ruby/docs/reference/google-cloud-gdc_hardware_management-v1alpha/latest) +for class and method documentation. + +See also the [Product Documentation](https://cloud.google.com/distributed-cloud/edge/latest/docs) +for general usage information. + +## Debug Logging + +This library comes with opt-in Debug Logging that can help you troubleshoot +your application's integration with the API. When logging is activated, key +events such as requests and responses, along with data payloads and metadata +such as headers and client configuration, are logged to the standard error +stream. + +**WARNING:** Client Library Debug Logging includes your data payloads in +plaintext, which could include sensitive data such as PII for yourself or your +customers, private keys, or other security data that could be compromising if +leaked. Always practice good data hygiene with your application logs, and follow +the principle of least access. Google also recommends that Client Library Debug +Logging be enabled only temporarily during active debugging, and not used +permanently in production. + +To enable logging, set the environment variable `GOOGLE_SDK_RUBY_LOGGING_GEMS` +to the value `all`. Alternatively, you can set the value to a comma-delimited +list of client library gem names. This will select the default logging behavior, +which writes logs to the standard error stream. On a local workstation, this may +result in logs appearing on the console. When running on a Google Cloud hosting +service such as [Google Cloud Run](https://cloud.google.com/run), this generally +results in logs appearing alongside your application logs in the +[Google Cloud Logging](https://cloud.google.com/logging/) service. + +You can customize logging by modifying the `logger` configuration when +constructing a client object. For example: + +```ruby +require "google/cloud/gdc_hardware_management/v1alpha" +require "logger" + +client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.logger = Logger.new "my-app.log" +end +``` + +## Google Cloud Samples + +To browse ready to use code samples check [Google Cloud Samples](https://cloud.google.com/docs/samples). + +## Supported Ruby Versions + +This library is supported on Ruby 3.0+. + +Google provides official support for Ruby versions that are actively supported +by Ruby Core—that is, Ruby versions that are either in normal maintenance or +in security maintenance, and not end of life. Older versions of Ruby _may_ +still work, but are unsupported and not recommended. See +https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby +support schedule. + +## Which client should I use? + +Most modern Ruby client libraries for Google APIs come in two flavors: the main +client library with a name such as `google-cloud-gdc_hardware_management`, +and lower-level _versioned_ client libraries with names such as +`google-cloud-gdc_hardware_management-v1alpha`. +_In most cases, you should install the main client._ + +### What's the difference between the main client and a versioned client? + +A _versioned client_ provides a basic set of data types and client classes for +a _single version_ of a specific service. (That is, for a service with multiple +versions, there might be a separate versioned client for each service version.) +Most versioned clients are written and maintained by a code generator. + +The _main client_ is designed to provide you with the _recommended_ client +interfaces for the service. There will be only one main client for any given +service, even a service with multiple versions. The main client includes +factory methods for constructing the client objects we recommend for most +users. In some cases, those will be classes provided by an underlying versioned +client; in other cases, they will be handwritten higher-level client objects +with additional capabilities, convenience methods, or best practices built in. +Generally, the main client will default to a recommended service version, +although in some cases you can override this if you need to talk to a specific +service version. + +### Why would I want to use the main client? + +We recommend that most users install the main client gem for a service. You can +identify this gem as the one _without_ a version in its name, e.g. +`google-cloud-gdc_hardware_management`. +The main client is recommended because it will embody the best practices for +accessing the service, and may also provide more convenient interfaces or +tighter integration into frameworks and third-party libraries. In addition, the +documentation and samples published by Google will generally demonstrate use of +the main client. + +### Why would I want to use a versioned client? + +You can use a versioned client if you are content with a possibly lower-level +class interface, you explicitly want to avoid features provided by the main +client, or you want to access a specific service version not be covered by the +main client. You can identify versioned client gems because the service version +is part of the name, e.g. `google-cloud-gdc_hardware_management-v1alpha`. + +### What about the google-apis- clients? + +Client library gems with names that begin with `google-apis-` are based on an +older code generation technology. They talk to a REST/JSON backend (whereas +most modern clients talk to a [gRPC](https://grpc.io/) backend) and they may +not offer the same performance, features, and ease of use provided by more +modern clients. + +The `google-apis-` clients have wide coverage across Google services, so you +might need to use one if there is no modern client available for the service. +However, if a modern client is available, we generally recommend it over the +older `google-apis-` clients. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile new file mode 100644 index 000000000000..dd6a7f239d3d --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile @@ -0,0 +1,169 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "bundler/setup" +require "bundler/gem_tasks" + +require "rubocop/rake_task" +RuboCop::RakeTask.new + +require "rake/testtask" +desc "Run tests." +Rake::TestTask.new do |t| + t.libs << "test" + t.test_files = FileList["test/**/*_test.rb"] + t.warning = false +end + +desc "Runs the smoke tests." +Rake::TestTask.new :smoke_test do |t| + t.test_files = FileList["acceptance/**/*smoke_test.rb"] + t.warning = false +end + +# Acceptance tests +desc "Run the google-cloud-gdc_hardware_management-v1alpha acceptance tests." +task :acceptance, :project, :keyfile do |t, args| + project = args[:project] + project ||= + ENV["GOOGLE_CLOUD_TEST_PROJECT"] || + ENV["GCLOUD_TEST_PROJECT"] + keyfile = args[:keyfile] + keyfile ||= + ENV["GOOGLE_CLOUD_TEST_KEYFILE"] || + ENV["GCLOUD_TEST_KEYFILE"] + if keyfile + keyfile = File.read keyfile + else + keyfile ||= + ENV["GOOGLE_CLOUD_TEST_KEYFILE_JSON"] || + ENV["GCLOUD_TEST_KEYFILE_JSON"] + end + if project.nil? || keyfile.nil? + fail "You must provide a project and keyfile. e.g. rake acceptance[test123, /path/to/keyfile.json] or GOOGLE_CLOUD_TEST_PROJECT=test123 GOOGLE_CLOUD_TEST_KEYFILE=/path/to/keyfile.json rake acceptance" + end + require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Credentials.env_vars.each do |path| + ENV[path] = nil + end + ENV["GOOGLE_CLOUD_PROJECT"] = project + ENV["GOOGLE_CLOUD_TEST_PROJECT"] = project + ENV["GOOGLE_CLOUD_KEYFILE_JSON"] = keyfile + + Rake::Task["acceptance:run"].invoke +end + +namespace :acceptance do + task :run do + if File.directory? "acceptance" + Rake::Task[:smoke_test].invoke + else + puts "The google-cloud-gdc_hardware_management-v1alpha gem has no acceptance tests." + end + end + + desc "Run acceptance cleanup." + task :cleanup do + end +end + +task :samples do + Rake::Task["samples:latest"].invoke +end + +namespace :samples do + task :latest do + if File.directory? "samples" + Dir.chdir "samples" do + Bundler.with_clean_env do + ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "not_master" + sh "bundle update" + sh "bundle exec rake test" + end + end + else + puts "The google-cloud-gdc_hardware_management-v1alpha gem has no samples to test." + end + end + + task :master do + if File.directory? "samples" + Dir.chdir "samples" do + Bundler.with_clean_env do + ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "master" + sh "bundle update" + sh "bundle exec rake test" + end + end + else + puts "The google-cloud-gdc_hardware_management-v1alpha gem has no samples to test." + end + end +end + +require "yard" +require "yard/rake/yardoc_task" +YARD::Rake::YardocTask.new do |y| + y.options << "--fail-on-warning" +end + +desc "Run yard-doctest example tests." +task :doctest do + puts "The google-cloud-gdc_hardware_management-v1alpha gem does not have doctest tests." +end + +desc "Run the CI build" +task :ci do + header "BUILDING google-cloud-gdc_hardware_management-v1alpha" + header "google-cloud-gdc_hardware_management-v1alpha rubocop", "*" + Rake::Task[:rubocop].invoke + header "google-cloud-gdc_hardware_management-v1alpha yard", "*" + Rake::Task[:yard].invoke + header "google-cloud-gdc_hardware_management-v1alpha test", "*" + Rake::Task[:test].invoke +end + +namespace :ci do + desc "Run the CI build, with smoke tests." + task :smoke_test do + Rake::Task[:ci].invoke + header "google-cloud-gdc_hardware_management-v1alpha smoke_test", "*" + Rake::Task[:smoke_test].invoke + end + desc "Run the CI build, with acceptance tests." + task :acceptance do + Rake::Task[:ci].invoke + header "google-cloud-gdc_hardware_management-v1alpha acceptance", "*" + Rake::Task[:acceptance].invoke + end + task :a do + # This is a handy shortcut to save typing + Rake::Task["ci:acceptance"].invoke + end +end + +task default: :test + +def header str, token = "#" + line_length = str.length + 8 + puts "" + puts token * line_length + puts "#{token * 3} #{str} #{token * 3}" + puts token * line_length + puts "" +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json new file mode 100644 index 000000000000..87a29abf2b0e --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json @@ -0,0 +1,203 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "ruby", + "protoPackage": "google.cloud.gdchardwaremanagement.v1alpha", + "libraryPackage": "::Google::Cloud::GDCHardwareManagement::V1alpha", + "services": { + "GDCHardwareManagement": { + "clients": { + "grpc": { + "libraryClient": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client", + "rpcs": { + "ListOrders": { + "methods": [ + "list_orders" + ] + }, + "GetOrder": { + "methods": [ + "get_order" + ] + }, + "CreateOrder": { + "methods": [ + "create_order" + ] + }, + "UpdateOrder": { + "methods": [ + "update_order" + ] + }, + "DeleteOrder": { + "methods": [ + "delete_order" + ] + }, + "SubmitOrder": { + "methods": [ + "submit_order" + ] + }, + "CancelOrder": { + "methods": [ + "cancel_order" + ] + }, + "ListSites": { + "methods": [ + "list_sites" + ] + }, + "GetSite": { + "methods": [ + "get_site" + ] + }, + "CreateSite": { + "methods": [ + "create_site" + ] + }, + "UpdateSite": { + "methods": [ + "update_site" + ] + }, + "DeleteSite": { + "methods": [ + "delete_site" + ] + }, + "ListHardwareGroups": { + "methods": [ + "list_hardware_groups" + ] + }, + "GetHardwareGroup": { + "methods": [ + "get_hardware_group" + ] + }, + "CreateHardwareGroup": { + "methods": [ + "create_hardware_group" + ] + }, + "UpdateHardwareGroup": { + "methods": [ + "update_hardware_group" + ] + }, + "DeleteHardwareGroup": { + "methods": [ + "delete_hardware_group" + ] + }, + "ListHardware": { + "methods": [ + "list_hardware" + ] + }, + "GetHardware": { + "methods": [ + "get_hardware" + ] + }, + "CreateHardware": { + "methods": [ + "create_hardware" + ] + }, + "UpdateHardware": { + "methods": [ + "update_hardware" + ] + }, + "DeleteHardware": { + "methods": [ + "delete_hardware" + ] + }, + "ListComments": { + "methods": [ + "list_comments" + ] + }, + "GetComment": { + "methods": [ + "get_comment" + ] + }, + "CreateComment": { + "methods": [ + "create_comment" + ] + }, + "RecordActionOnComment": { + "methods": [ + "record_action_on_comment" + ] + }, + "ListChangeLogEntries": { + "methods": [ + "list_change_log_entries" + ] + }, + "GetChangeLogEntry": { + "methods": [ + "get_change_log_entry" + ] + }, + "ListSkus": { + "methods": [ + "list_skus" + ] + }, + "GetSku": { + "methods": [ + "get_sku" + ] + }, + "ListZones": { + "methods": [ + "list_zones" + ] + }, + "GetZone": { + "methods": [ + "get_zone" + ] + }, + "CreateZone": { + "methods": [ + "create_zone" + ] + }, + "UpdateZone": { + "methods": [ + "update_zone" + ] + }, + "DeleteZone": { + "methods": [ + "delete_zone" + ] + }, + "SignalZoneState": { + "methods": [ + "signal_zone_state" + ] + }, + "RequestOrderDateChange": { + "methods": [ + "request_order_date_change" + ] + } + } + } + } + } + } +} diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec new file mode 100644 index 000000000000..fa8f96ea06dc --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec @@ -0,0 +1,29 @@ +# -*- ruby -*- +# encoding: utf-8 + +require File.expand_path("lib/google/cloud/gdc_hardware_management/v1alpha/version", __dir__) + +Gem::Specification.new do |gem| + gem.name = "google-cloud-gdc_hardware_management-v1alpha" + gem.version = Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + + gem.authors = ["Google LLC"] + gem.email = "googleapis-packages@google.com" + gem.description = "google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. Note that google-cloud-gdc_hardware_management-v1alpha is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-gdc_hardware_management instead. See the readme for more details." + gem.summary = "API Client library for the GDC Hardware Management V1ALPHA API" + gem.homepage = "https://github.com/googleapis/google-cloud-ruby" + gem.license = "Apache-2.0" + + gem.platform = Gem::Platform::RUBY + + gem.files = `git ls-files -- lib/*`.split("\n") + + `git ls-files -- proto_docs/*`.split("\n") + + ["README.md", "LICENSE.md", "AUTHENTICATION.md", ".yardopts"] + gem.require_paths = ["lib"] + + gem.required_ruby_version = ">= 3.1" + + gem.add_dependency "gapic-common", "~> 1.2" + gem.add_dependency "google-cloud-errors", "~> 1.0" + gem.add_dependency "google-cloud-location", "~> 1.0" +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb new file mode 100644 index 000000000000..d40020ca9852 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# This gem does not autoload during Bundler.require. To load this gem, +# issue explicit require statements for the packages desired, e.g.: +# require "google/cloud/gdc_hardware_management/v1alpha" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb new file mode 100644 index 000000000000..6db51170738a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" +require "google/cloud/gdc_hardware_management/v1alpha/version" + +module Google + module Cloud + module GDCHardwareManagement + ## + # API client module. + # + # @example Load this package, including all its services, and instantiate a gRPC client + # + # require "google/cloud/gdc_hardware_management/v1alpha" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # @example Load this package, including all its services, and instantiate a REST client + # + # require "google/cloud/gdc_hardware_management/v1alpha" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + module V1alpha + end + end + end +end + +helper_path = ::File.join __dir__, "v1alpha", "_helpers.rb" +require "google/cloud/gdc_hardware_management/v1alpha/_helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb new file mode 100644 index 000000000000..d13989b04895 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb @@ -0,0 +1,75 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/rest" + +module Google + module Cloud + module GDCHardwareManagement + ## + # @example Loading just the REST part of this package, including all its services, and instantiating a REST client + # + # require "google/cloud/gdc_hardware_management/v1alpha/rest" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + module V1alpha + ## + # @private + # Initialize the mixin bindings configuration + # + def self.configure + @configure ||= begin + namespace = ["Google", "Cloud", "GDCHardwareManagement"] + parent_config = while namespace.any? + parent_name = namespace.join "::" + parent_const = const_get parent_name + break parent_const.configure if parent_const.respond_to? :configure + namespace.pop + end + + default_config = ::Gapic::Rest::HttpBindingOverrideConfiguration.new parent_config + default_config.bindings_override["google.cloud.location.Locations.GetLocation"] = [ + Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ], + body: nil + ) + ] + default_config.bindings_override["google.cloud.location.Locations.ListLocations"] = [ + + Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( + uri_method: :get, + uri_template: "/v1alpha/{name}/locations", + matches: [ + ["name", %r{^projects/[^/]+/?$}, false] + ], + body: nil + ) + ] + default_config + end + yield @configure if block_given? + @configure + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb new file mode 100644 index 000000000000..954c647498da --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/common" +require "gapic/config" +require "gapic/config/method" + +require "google/cloud/gdc_hardware_management/v1alpha/version" + +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + ## + # The GDC Hardware Management service. + # + # @example Load this service and instantiate a gRPC client + # + # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # @example Load this service and instantiate a REST client + # + # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + module GDCHardwareManagement + end + end + end + end +end + +helper_path = ::File.join __dir__, "gdc_hardware_management", "helpers.rb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb new file mode 100644 index 000000000000..aa86199e8d7b --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb @@ -0,0 +1,4499 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/errors" +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" +require "google/cloud/location" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + ## + # Client for the GDCHardwareManagement service. + # + # The GDC Hardware Management service. + # + class Client + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" + + include Paths + + # @private + attr_reader :gdc_hardware_management_stub + + ## + # Configure the GDCHardwareManagement Client class. + # + # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration} + # for a description of the configuration fields. + # + # @example + # + # # Modify the configuration for all GDCHardwareManagement clients + # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def self.configure + @configure ||= begin + namespace = ["Google", "Cloud", "GDCHardwareManagement", "V1alpha"] + parent_config = while namespace.any? + parent_name = namespace.join "::" + parent_const = const_get parent_name + break parent_const.configure if parent_const.respond_to? :configure + namespace.pop + end + default_config = Client::Configuration.new parent_config + + default_config.rpcs.list_orders.timeout = 60.0 + default_config.rpcs.list_orders.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_order.timeout = 60.0 + default_config.rpcs.get_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_order.timeout = 60.0 + + default_config.rpcs.update_order.timeout = 60.0 + default_config.rpcs.update_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_order.timeout = 60.0 + default_config.rpcs.delete_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.submit_order.timeout = 60.0 + default_config.rpcs.submit_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.cancel_order.timeout = 60.0 + default_config.rpcs.cancel_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_sites.timeout = 60.0 + default_config.rpcs.list_sites.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_site.timeout = 60.0 + default_config.rpcs.get_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_site.timeout = 60.0 + + default_config.rpcs.update_site.timeout = 60.0 + default_config.rpcs.update_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_site.timeout = 60.0 + default_config.rpcs.delete_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_hardware_groups.timeout = 60.0 + default_config.rpcs.list_hardware_groups.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_hardware_group.timeout = 60.0 + default_config.rpcs.get_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_hardware_group.timeout = 60.0 + + default_config.rpcs.update_hardware_group.timeout = 60.0 + default_config.rpcs.update_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_hardware_group.timeout = 60.0 + default_config.rpcs.delete_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_hardware.timeout = 60.0 + default_config.rpcs.list_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_hardware.timeout = 60.0 + default_config.rpcs.get_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_hardware.timeout = 60.0 + + default_config.rpcs.update_hardware.timeout = 60.0 + default_config.rpcs.update_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_hardware.timeout = 60.0 + default_config.rpcs.delete_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_comments.timeout = 60.0 + default_config.rpcs.list_comments.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_comment.timeout = 60.0 + default_config.rpcs.get_comment.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_comment.timeout = 60.0 + + default_config.rpcs.list_change_log_entries.timeout = 60.0 + default_config.rpcs.list_change_log_entries.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_change_log_entry.timeout = 60.0 + default_config.rpcs.get_change_log_entry.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_skus.timeout = 60.0 + default_config.rpcs.list_skus.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_sku.timeout = 60.0 + default_config.rpcs.get_sku.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_zones.timeout = 60.0 + default_config.rpcs.list_zones.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_zone.timeout = 60.0 + default_config.rpcs.get_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_zone.timeout = 60.0 + + default_config.rpcs.update_zone.timeout = 60.0 + default_config.rpcs.update_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_zone.timeout = 60.0 + default_config.rpcs.delete_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config + end + yield @configure if block_given? + @configure + end + + ## + # Configure the GDCHardwareManagement Client instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Client.configure}. + # + # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration} + # for a description of the configuration fields. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @gdc_hardware_management_stub.universe_domain + end + + ## + # Create a new GDCHardwareManagement client object. + # + # @example + # + # # Create a client using the default configuration + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a client using a custom configuration + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the GDCHardwareManagement client. + # @yieldparam config [Client::Configuration] + # + def initialize + # These require statements are intentionally placed here to initialize + # the gRPC module only when it's required. + # See https://github.com/googleapis/toolkit/issues/446 + require "gapic/grpc" + require "google/cloud/gdchardwaremanagement/v1alpha/service_services_pb" + + # Create the configuration object + @config = Configuration.new Client.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + # Use self-signed JWT if the endpoint is unchanged from default, + # but only if the default endpoint does not have a region prefix. + enable_self_signed_jwt = @config.endpoint.nil? || + (@config.endpoint == Configuration::DEFAULT_ENDPOINT && + !@config.endpoint.split(".").first.include?("-")) + credentials ||= Credentials.default scope: @config.scope, + enable_self_signed_jwt: enable_self_signed_jwt + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_client = Operations.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @config.endpoint + config.universe_domain = @config.universe_domain + end + + @gdc_hardware_management_stub = ::Gapic::ServiceStub.new( + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Stub, + credentials: credentials, + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + channel_args: @config.channel_args, + interceptors: @config.interceptors, + channel_pool_config: @config.channel_pool, + logger: @config.logger + ) + + @gdc_hardware_management_stub.stub_logger&.info do |entry| + entry.set_system_name + entry.set_service + entry.message = "Created client for #{entry.service}" + entry.set_credentials_fields credentials + entry.set "customEndpoint", @config.endpoint if @config.endpoint + entry.set "defaultTimeout", @config.timeout if @config.timeout + entry.set "quotaProject", @quota_project_id if @quota_project_id + end + + @location_client = Google::Cloud::Location::Locations::Client.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @gdc_hardware_management_stub.endpoint + config.universe_domain = @gdc_hardware_management_stub.universe_domain + config.logger = @gdc_hardware_management_stub.logger if config.respond_to? :logger= + end + end + + ## + # Get the associated client for long-running operations. + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations] + # + attr_reader :operations_client + + ## + # Get the associated client for mix-in of the Locations. + # + # @return [Google::Cloud::Location::Locations::Client] + # + attr_reader :location_client + + ## + # The logger used for request/response debug logging. + # + # @return [Logger] + # + def logger + @gdc_hardware_management_stub.logger + end + + # Service calls + + ## + # Lists orders in a given project and location. + # + # @overload list_orders(request, options = nil) + # Pass arguments to `list_orders` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_orders(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_orders` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list orders in. + # Format: `projects/{project}/locations/{location}` + # + # To list orders across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new + # + # # Call the list_orders method. + # result = client.list_orders request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. + # p item + # end + # + def list_orders request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_orders.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_orders.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_orders.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_orders, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_orders, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of an order. + # + # @overload get_order(request, options = nil) + # Pass arguments to `get_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_order(name: nil) + # Pass arguments to `get_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. Name of the resource + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new + # + # # Call the get_order method. + # result = client.get_order request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. + # p result + # + def get_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_order, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new order in a given project and location. + # + # @overload create_order(request, options = nil) + # Pass arguments to `create_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_order(parent: nil, order_id: nil, order: nil, request_id: nil) + # Pass arguments to `create_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the order in. + # Format: `projects/{project}/locations/{location}` + # @param order_id [::String] + # Optional. ID used to uniquely identify the Order within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The order.name field in the request will be ignored. + # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] + # Required. The order to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new + # + # # Call the create_order method. + # result = client.create_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_order, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of an order. + # + # @overload update_order(request, options = nil) + # Pass arguments to `update_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload update_order(update_mask: nil, order: nil, request_id: nil) + # Pass arguments to `update_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Order to overwrite with this + # update. The fields specified in the update_mask are relative to the order, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] + # Required. The order to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new + # + # # Call the update_order method. + # result = client.update_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.update_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.order&.name + header_params["order.name"] = request.order.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.update_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.update_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :update_order, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes an order. + # + # @overload delete_order(request, options = nil) + # Pass arguments to `delete_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_order(name: nil, request_id: nil, force: nil) + # Pass arguments to `delete_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param force [::Boolean] + # Optional. An option to delete any nested resources in the Order, such as a + # HardwareGroup. If true, any nested resources for this Order will also be + # deleted. Otherwise, the request will only succeed if the Order has no + # nested resources. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new + # + # # Call the delete_order method. + # result = client.delete_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :delete_order, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Submits an order. + # + # @overload submit_order(request, options = nil) + # Pass arguments to `submit_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload submit_order(name: nil, request_id: nil, type: nil) + # Pass arguments to `submit_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param type [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] + # Optional. Type of this request. If unset, the request type is assumed to be + # `INFO_PENDING`. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new + # + # # Call the submit_order method. + # result = client.submit_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def submit_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.submit_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.submit_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.submit_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :submit_order, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Cancels an order. + # + # @overload cancel_order(request, options = nil) + # Pass arguments to `cancel_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload cancel_order(name: nil, request_id: nil) + # Pass arguments to `cancel_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new + # + # # Call the cancel_order method. + # result = client.cancel_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def cancel_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.cancel_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.cancel_order.timeout, + metadata: metadata, + retry_policy: @config.rpcs.cancel_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :cancel_order, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists sites in a given project and location. + # + # @overload list_sites(request, options = nil) + # Pass arguments to `list_sites` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_sites(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_sites` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list sites in. + # Format: `projects/{project}/locations/{location}` + # + # To list sites across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new + # + # # Call the list_sites method. + # result = client.list_sites request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. + # p item + # end + # + def list_sites request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_sites.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_sites.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_sites.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_sites, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_sites, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a site. + # + # @overload get_site(request, options = nil) + # Pass arguments to `get_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_site(name: nil) + # Pass arguments to `get_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new + # + # # Call the get_site method. + # result = client.get_site request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. + # p result + # + def get_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_site.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_site, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new site in a given project and location. + # + # @overload create_site(request, options = nil) + # Pass arguments to `create_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_site(parent: nil, site_id: nil, site: nil, request_id: nil) + # Pass arguments to `create_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the site in. + # Format: `projects/{project}/locations/{location}` + # @param site_id [::String] + # Optional. ID used to uniquely identify the Site within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The site.name field in the request will be ignored. + # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] + # Required. The site to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new + # + # # Call the create_site method. + # result = client.create_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_site.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_site, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a site. + # + # @overload update_site(request, options = nil) + # Pass arguments to `update_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload update_site(update_mask: nil, site: nil, request_id: nil) + # Pass arguments to `update_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Site to overwrite with this + # update. The fields specified in the update_mask are relative to the site, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] + # Required. The site to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new + # + # # Call the update_site method. + # result = client.update_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.update_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.site&.name + header_params["site.name"] = request.site.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.update_site.timeout, + metadata: metadata, + retry_policy: @config.rpcs.update_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :update_site, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a site. + # + # @overload delete_site(request, options = nil) + # Pass arguments to `delete_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_site(name: nil, request_id: nil) + # Pass arguments to `delete_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new + # + # # Call the delete_site method. + # result = client.delete_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_site.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :delete_site, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists hardware groups in a given order. + # + # @overload list_hardware_groups(request, options = nil) + # Pass arguments to `list_hardware_groups` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_hardware_groups(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_hardware_groups` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list hardware groups in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new + # + # # Call the list_hardware_groups method. + # result = client.list_hardware_groups request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + # p item + # end + # + def list_hardware_groups request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_hardware_groups.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_hardware_groups.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_hardware_groups.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_hardware_groups, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware_groups, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a hardware group. + # + # @overload get_hardware_group(request, options = nil) + # Pass arguments to `get_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_hardware_group(name: nil) + # Pass arguments to `get_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new + # + # # Call the get_hardware_group method. + # result = client.get_hardware_group request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + # p result + # + def get_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_hardware_group.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_hardware_group, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new hardware group in a given order. + # + # @overload create_hardware_group(request, options = nil) + # Pass arguments to `create_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_hardware_group(parent: nil, hardware_group_id: nil, hardware_group: nil, request_id: nil) + # Pass arguments to `create_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to create the hardware group in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param hardware_group_id [::String] + # Optional. ID used to uniquely identify the HardwareGroup within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware_group.name field in the request will be ignored. + # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] + # Required. The hardware group to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new + # + # # Call the create_hardware_group method. + # result = client.create_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_hardware_group.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_hardware_group, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a hardware group. + # + # @overload update_hardware_group(request, options = nil) + # Pass arguments to `update_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload update_hardware_group(update_mask: nil, hardware_group: nil, request_id: nil) + # Pass arguments to `update_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the HardwareGroup to overwrite + # with this update. The fields specified in the update_mask are relative to + # the hardware group, not the full request. A field will be overwritten if it + # is in the mask. If you don't provide a mask then all fields will be + # overwritten. + # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] + # Required. The hardware group to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new + # + # # Call the update_hardware_group method. + # result = client.update_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.update_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.hardware_group&.name + header_params["hardware_group.name"] = request.hardware_group.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.update_hardware_group.timeout, + metadata: metadata, + retry_policy: @config.rpcs.update_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :update_hardware_group, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a hardware group. + # + # @overload delete_hardware_group(request, options = nil) + # Pass arguments to `delete_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_hardware_group(name: nil, request_id: nil) + # Pass arguments to `delete_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new + # + # # Call the delete_hardware_group method. + # result = client.delete_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_hardware_group.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :delete_hardware_group, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists hardware in a given project and location. + # + # @overload list_hardware(request, options = nil) + # Pass arguments to `list_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_hardware(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list hardware in. + # Format: `projects/{project}/locations/{location}` + # + # To list hardware across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new + # + # # Call the list_hardware method. + # result = client.list_hardware request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + # p item + # end + # + def list_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_hardware.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_hardware, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets hardware details. + # + # @overload get_hardware(request, options = nil) + # Pass arguments to `get_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_hardware(name: nil) + # Pass arguments to `get_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new + # + # # Call the get_hardware method. + # result = client.get_hardware request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + # p result + # + def get_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_hardware.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_hardware, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates new hardware in a given project and location. + # + # @overload create_hardware(request, options = nil) + # Pass arguments to `create_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_hardware(parent: nil, hardware_id: nil, hardware: nil) + # Pass arguments to `create_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create hardware in. + # Format: `projects/{project}/locations/{location}` + # @param hardware_id [::String] + # Optional. ID used to uniquely identify the Hardware within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware.name field in the request will be ignored. + # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] + # Required. The resource to create. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new + # + # # Call the create_hardware method. + # result = client.create_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_hardware.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_hardware, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates hardware parameters. + # + # @overload update_hardware(request, options = nil) + # Pass arguments to `update_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload update_hardware(update_mask: nil, hardware: nil, request_id: nil) + # Pass arguments to `update_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Hardware to overwrite with + # this update. The fields specified in the update_mask are relative to the + # hardware, not the full request. A field will be overwritten if it is in the + # mask. If you don't provide a mask then all fields will be overwritten. + # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] + # Required. The hardware to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new + # + # # Call the update_hardware method. + # result = client.update_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.update_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.hardware&.name + header_params["hardware.name"] = request.hardware.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.update_hardware.timeout, + metadata: metadata, + retry_policy: @config.rpcs.update_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :update_hardware, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes hardware. + # + # @overload delete_hardware(request, options = nil) + # Pass arguments to `delete_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_hardware(name: nil, request_id: nil) + # Pass arguments to `delete_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new + # + # # Call the delete_hardware method. + # result = client.delete_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_hardware.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :delete_hardware, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the comments on an order. + # + # @overload list_comments(request, options = nil) + # Pass arguments to `list_comments` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_comments(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_comments` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list comments on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new + # + # # Call the list_comments method. + # result = client.list_comments request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p item + # end + # + def list_comments request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_comments.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_comments.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_comments.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_comments, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_comments, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the content of a comment. + # + # @overload get_comment(request, options = nil) + # Pass arguments to `get_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_comment(name: nil) + # Pass arguments to `get_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new + # + # # Call the get_comment method. + # result = client.get_comment request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p result + # + def get_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_comment.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_comment, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new comment on an order. + # + # @overload create_comment(request, options = nil) + # Pass arguments to `create_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_comment(parent: nil, comment_id: nil, comment: nil, request_id: nil) + # Pass arguments to `create_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to create the comment on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param comment_id [::String] + # Optional. ID used to uniquely identify the Comment within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The comment.name field in the request will be ignored. + # @param comment [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment, ::Hash] + # Required. The comment to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new + # + # # Call the create_comment method. + # result = client.create_comment request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_comment.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_comment, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Record Action on a Comment. If the Action specified in the request is READ, + # the viewed time in the comment is set to the time the request was received. + # If the comment is already marked as read, subsequent calls will be ignored. + # If the Action is UNREAD, the viewed time is cleared from the comment. + # + # @overload record_action_on_comment(request, options = nil) + # Pass arguments to `record_action_on_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload record_action_on_comment(name: nil, action_type: nil) + # Pass arguments to `record_action_on_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # @param action_type [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] + # Required. The action type of the recorded action. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new + # + # # Call the record_action_on_comment method. + # result = client.record_action_on_comment request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p result + # + def record_action_on_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.record_action_on_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.record_action_on_comment.timeout, + metadata: metadata, + retry_policy: @config.rpcs.record_action_on_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :record_action_on_comment, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the changes made to an order. + # + # @overload list_change_log_entries(request, options = nil) + # Pass arguments to `list_change_log_entries` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_change_log_entries(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_change_log_entries` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list change log entries for. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new + # + # # Call the list_change_log_entries method. + # result = client.list_change_log_entries request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + # p item + # end + # + def list_change_log_entries request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_change_log_entries.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_change_log_entries.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_change_log_entries.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_change_log_entries, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_change_log_entries, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a change to an order. + # + # @overload get_change_log_entry(request, options = nil) + # Pass arguments to `get_change_log_entry` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_change_log_entry(name: nil) + # Pass arguments to `get_change_log_entry` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the change log entry. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new + # + # # Call the get_change_log_entry method. + # result = client.get_change_log_entry request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + # p result + # + def get_change_log_entry request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_change_log_entry.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_change_log_entry.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_change_log_entry.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_change_log_entry, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists SKUs for a given project and location. + # + # @overload list_skus(request, options = nil) + # Pass arguments to `list_skus` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_skus(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_skus` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list SKUs in. + # Format: `projects/{project}/locations/{location}` + # + # To list SKUs across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new + # + # # Call the list_skus method. + # result = client.list_skus request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + # p item + # end + # + def list_skus request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_skus.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_skus.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_skus.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_skus, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_skus, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of an SKU. + # + # @overload get_sku(request, options = nil) + # Pass arguments to `get_sku` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_sku(name: nil) + # Pass arguments to `get_sku` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the SKU. + # Format: `projects/{project}/locations/{location}/skus/{sku}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new + # + # # Call the get_sku method. + # result = client.get_sku request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + # p result + # + def get_sku request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_sku.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_sku.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_sku.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_sku, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists zones in a given project and location. + # + # @overload list_zones(request, options = nil) + # Pass arguments to `list_zones` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_zones(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_zones` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list zones in. + # Format: `projects/{project}/locations/{location}` + # + # To list zones across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new + # + # # Call the list_zones method. + # result = client.list_zones request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + # p item + # end + # + def list_zones request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_zones.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_zones.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_zones.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :list_zones, request, options: options do |response, operation| + response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_zones, request, response, operation, options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a zone. + # + # @overload get_zone(request, options = nil) + # Pass arguments to `get_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_zone(name: nil) + # Pass arguments to `get_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new + # + # # Call the get_zone method. + # result = client.get_zone request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + # p result + # + def get_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_zone.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :get_zone, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new zone in a given project and location. + # + # @overload create_zone(request, options = nil) + # Pass arguments to `create_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload create_zone(parent: nil, zone_id: nil, zone: nil, request_id: nil) + # Pass arguments to `create_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the zone in. + # Format: `projects/{project}/locations/{location}` + # @param zone_id [::String] + # Optional. ID used to uniquely identify the Zone within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The zone.name field in the request will be ignored. + # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] + # Required. The zone to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new + # + # # Call the create_zone method. + # result = client.create_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.create_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.parent + header_params["parent"] = request.parent + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.create_zone.timeout, + metadata: metadata, + retry_policy: @config.rpcs.create_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :create_zone, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a zone. + # + # @overload update_zone(request, options = nil) + # Pass arguments to `update_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload update_zone(update_mask: nil, zone: nil, request_id: nil) + # Pass arguments to `update_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Zone to overwrite with this + # update. The fields specified in the update_mask are relative to the zone, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] + # Required. The zone to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new + # + # # Call the update_zone method. + # result = client.update_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.update_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.zone&.name + header_params["zone.name"] = request.zone.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.update_zone.timeout, + metadata: metadata, + retry_policy: @config.rpcs.update_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :update_zone, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a zone. + # + # @overload delete_zone(request, options = nil) + # Pass arguments to `delete_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_zone(name: nil, request_id: nil) + # Pass arguments to `delete_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new + # + # # Call the delete_zone method. + # result = client.delete_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_zone.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :delete_zone, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Signals the state of a zone. + # + # @overload signal_zone_state(request, options = nil) + # Pass arguments to `signal_zone_state` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload signal_zone_state(name: nil, request_id: nil, state_signal: nil, provisioning_state_signal: nil, step: nil, details: nil) + # Pass arguments to `signal_zone_state` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] + # Optional. The state signal to send for this zone. Either state_signal or + # provisioning_state_signal must be set, but not both. + # @param provisioning_state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] + # Optional. The provisioning state signal to send for this zone. Either + # state_signal or provisioning_state_signal must be set, but not both. + # @param step [::String] + # Optional. The step being executed. Provides a finer grained status when the + # state_signal is FACTORY_TURNUP_CHECKS_STARTED or + # FACTORY_TURNUP_CHECKS_FAILED. + # @param details [::String] + # Optional. Additional details, such as an error message when state_signal is + # FACTORY_TURNUP_CHECKS_FAILED. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new + # + # # Call the signal_zone_state method. + # result = client.signal_zone_state request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def signal_zone_state request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.signal_zone_state.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.signal_zone_state.timeout, + metadata: metadata, + retry_policy: @config.rpcs.signal_zone_state.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :signal_zone_state, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the requested date change of a single Order. + # + # @overload request_order_date_change(request, options = nil) + # Pass arguments to `request_order_date_change` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload request_order_date_change(name: nil, requested_date: nil) + # Pass arguments to `request_order_date_change` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order to update. + # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} + # @param requested_date [::Google::Type::Date, ::Hash] + # Required. The date to which the customer or Google wants to set the + # scheduled installation date. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new + # + # # Call the request_order_date_change method. + # result = client.request_order_date_change request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def request_order_date_change request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.request_order_date_change.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.request_order_date_change.timeout, + metadata: metadata, + retry_policy: @config.rpcs.request_order_date_change.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.call_rpc :request_order_date_change, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the GDCHardwareManagement API. + # + # This class represents the configuration for GDCHardwareManagement, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_orders to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_orders.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_orders.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`GRPC::Core::Channel`) a gRPC channel with included credentials + # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object + # * (`nil`) indicating no credentials + # + # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials + # is deprecated. Providing an unvalidated credential configuration to + # Google APIs can compromise the security of your systems and data. + # + # @example + # + # # The recommended way to provide credentials is to use the `make_creds` method + # # on the appropriate credentials class for your environment. + # + # require "googleauth" + # + # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds( + # json_key_io: ::File.open("/path/to/keyfile.json") + # ) + # + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + # config.credentials = credentials + # end + # + # @note Warning: If you accept a credential configuration (JSON file or Hash) from an + # external source for authentication to Google Cloud, you must validate it before + # providing it to a Google API client library. Providing an unvalidated credential + # configuration to Google APIs can compromise the security of your systems and data. + # For more information, refer to [Validate credential configurations from external + # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] channel_args + # Extra parameters passed to the gRPC channel. Note: this is ignored if a + # `GRPC::Core::Channel` object is provided as the credential. + # @return [::Hash] + # @!attribute [rw] interceptors + # An array of interceptors that are run before calls are executed. + # @return [::Array<::GRPC::ClientInterceptor>] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional gRPC headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # @!attribute [rw] logger + # A custom logger to use for request/response debug logging, or the value + # `:default` (the default) to construct a default logger, or `nil` to + # explicitly disable logging. + # @return [::Logger,:default,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] + allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC::Core::Channel + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil) + config_attr :interceptors, nil, ::Array, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + config_attr :logger, :default, ::Logger, nil, :default + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration for the channel pool + # @return [::Gapic::ServiceStub::ChannelPool::Configuration] + # + def channel_pool + @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new + end + + ## + # Configuration RPC class for the GDCHardwareManagement API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_orders` + # @return [::Gapic::Config::Method] + # + attr_reader :list_orders + ## + # RPC-specific configuration for `get_order` + # @return [::Gapic::Config::Method] + # + attr_reader :get_order + ## + # RPC-specific configuration for `create_order` + # @return [::Gapic::Config::Method] + # + attr_reader :create_order + ## + # RPC-specific configuration for `update_order` + # @return [::Gapic::Config::Method] + # + attr_reader :update_order + ## + # RPC-specific configuration for `delete_order` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_order + ## + # RPC-specific configuration for `submit_order` + # @return [::Gapic::Config::Method] + # + attr_reader :submit_order + ## + # RPC-specific configuration for `cancel_order` + # @return [::Gapic::Config::Method] + # + attr_reader :cancel_order + ## + # RPC-specific configuration for `list_sites` + # @return [::Gapic::Config::Method] + # + attr_reader :list_sites + ## + # RPC-specific configuration for `get_site` + # @return [::Gapic::Config::Method] + # + attr_reader :get_site + ## + # RPC-specific configuration for `create_site` + # @return [::Gapic::Config::Method] + # + attr_reader :create_site + ## + # RPC-specific configuration for `update_site` + # @return [::Gapic::Config::Method] + # + attr_reader :update_site + ## + # RPC-specific configuration for `delete_site` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_site + ## + # RPC-specific configuration for `list_hardware_groups` + # @return [::Gapic::Config::Method] + # + attr_reader :list_hardware_groups + ## + # RPC-specific configuration for `get_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :get_hardware_group + ## + # RPC-specific configuration for `create_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :create_hardware_group + ## + # RPC-specific configuration for `update_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :update_hardware_group + ## + # RPC-specific configuration for `delete_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_hardware_group + ## + # RPC-specific configuration for `list_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :list_hardware + ## + # RPC-specific configuration for `get_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :get_hardware + ## + # RPC-specific configuration for `create_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :create_hardware + ## + # RPC-specific configuration for `update_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :update_hardware + ## + # RPC-specific configuration for `delete_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_hardware + ## + # RPC-specific configuration for `list_comments` + # @return [::Gapic::Config::Method] + # + attr_reader :list_comments + ## + # RPC-specific configuration for `get_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :get_comment + ## + # RPC-specific configuration for `create_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :create_comment + ## + # RPC-specific configuration for `record_action_on_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :record_action_on_comment + ## + # RPC-specific configuration for `list_change_log_entries` + # @return [::Gapic::Config::Method] + # + attr_reader :list_change_log_entries + ## + # RPC-specific configuration for `get_change_log_entry` + # @return [::Gapic::Config::Method] + # + attr_reader :get_change_log_entry + ## + # RPC-specific configuration for `list_skus` + # @return [::Gapic::Config::Method] + # + attr_reader :list_skus + ## + # RPC-specific configuration for `get_sku` + # @return [::Gapic::Config::Method] + # + attr_reader :get_sku + ## + # RPC-specific configuration for `list_zones` + # @return [::Gapic::Config::Method] + # + attr_reader :list_zones + ## + # RPC-specific configuration for `get_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :get_zone + ## + # RPC-specific configuration for `create_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :create_zone + ## + # RPC-specific configuration for `update_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :update_zone + ## + # RPC-specific configuration for `delete_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_zone + ## + # RPC-specific configuration for `signal_zone_state` + # @return [::Gapic::Config::Method] + # + attr_reader :signal_zone_state + ## + # RPC-specific configuration for `request_order_date_change` + # @return [::Gapic::Config::Method] + # + attr_reader :request_order_date_change + + # @private + def initialize parent_rpcs = nil + list_orders_config = parent_rpcs.list_orders if parent_rpcs.respond_to? :list_orders + @list_orders = ::Gapic::Config::Method.new list_orders_config + get_order_config = parent_rpcs.get_order if parent_rpcs.respond_to? :get_order + @get_order = ::Gapic::Config::Method.new get_order_config + create_order_config = parent_rpcs.create_order if parent_rpcs.respond_to? :create_order + @create_order = ::Gapic::Config::Method.new create_order_config + update_order_config = parent_rpcs.update_order if parent_rpcs.respond_to? :update_order + @update_order = ::Gapic::Config::Method.new update_order_config + delete_order_config = parent_rpcs.delete_order if parent_rpcs.respond_to? :delete_order + @delete_order = ::Gapic::Config::Method.new delete_order_config + submit_order_config = parent_rpcs.submit_order if parent_rpcs.respond_to? :submit_order + @submit_order = ::Gapic::Config::Method.new submit_order_config + cancel_order_config = parent_rpcs.cancel_order if parent_rpcs.respond_to? :cancel_order + @cancel_order = ::Gapic::Config::Method.new cancel_order_config + list_sites_config = parent_rpcs.list_sites if parent_rpcs.respond_to? :list_sites + @list_sites = ::Gapic::Config::Method.new list_sites_config + get_site_config = parent_rpcs.get_site if parent_rpcs.respond_to? :get_site + @get_site = ::Gapic::Config::Method.new get_site_config + create_site_config = parent_rpcs.create_site if parent_rpcs.respond_to? :create_site + @create_site = ::Gapic::Config::Method.new create_site_config + update_site_config = parent_rpcs.update_site if parent_rpcs.respond_to? :update_site + @update_site = ::Gapic::Config::Method.new update_site_config + delete_site_config = parent_rpcs.delete_site if parent_rpcs.respond_to? :delete_site + @delete_site = ::Gapic::Config::Method.new delete_site_config + list_hardware_groups_config = parent_rpcs.list_hardware_groups if parent_rpcs.respond_to? :list_hardware_groups + @list_hardware_groups = ::Gapic::Config::Method.new list_hardware_groups_config + get_hardware_group_config = parent_rpcs.get_hardware_group if parent_rpcs.respond_to? :get_hardware_group + @get_hardware_group = ::Gapic::Config::Method.new get_hardware_group_config + create_hardware_group_config = parent_rpcs.create_hardware_group if parent_rpcs.respond_to? :create_hardware_group + @create_hardware_group = ::Gapic::Config::Method.new create_hardware_group_config + update_hardware_group_config = parent_rpcs.update_hardware_group if parent_rpcs.respond_to? :update_hardware_group + @update_hardware_group = ::Gapic::Config::Method.new update_hardware_group_config + delete_hardware_group_config = parent_rpcs.delete_hardware_group if parent_rpcs.respond_to? :delete_hardware_group + @delete_hardware_group = ::Gapic::Config::Method.new delete_hardware_group_config + list_hardware_config = parent_rpcs.list_hardware if parent_rpcs.respond_to? :list_hardware + @list_hardware = ::Gapic::Config::Method.new list_hardware_config + get_hardware_config = parent_rpcs.get_hardware if parent_rpcs.respond_to? :get_hardware + @get_hardware = ::Gapic::Config::Method.new get_hardware_config + create_hardware_config = parent_rpcs.create_hardware if parent_rpcs.respond_to? :create_hardware + @create_hardware = ::Gapic::Config::Method.new create_hardware_config + update_hardware_config = parent_rpcs.update_hardware if parent_rpcs.respond_to? :update_hardware + @update_hardware = ::Gapic::Config::Method.new update_hardware_config + delete_hardware_config = parent_rpcs.delete_hardware if parent_rpcs.respond_to? :delete_hardware + @delete_hardware = ::Gapic::Config::Method.new delete_hardware_config + list_comments_config = parent_rpcs.list_comments if parent_rpcs.respond_to? :list_comments + @list_comments = ::Gapic::Config::Method.new list_comments_config + get_comment_config = parent_rpcs.get_comment if parent_rpcs.respond_to? :get_comment + @get_comment = ::Gapic::Config::Method.new get_comment_config + create_comment_config = parent_rpcs.create_comment if parent_rpcs.respond_to? :create_comment + @create_comment = ::Gapic::Config::Method.new create_comment_config + record_action_on_comment_config = parent_rpcs.record_action_on_comment if parent_rpcs.respond_to? :record_action_on_comment + @record_action_on_comment = ::Gapic::Config::Method.new record_action_on_comment_config + list_change_log_entries_config = parent_rpcs.list_change_log_entries if parent_rpcs.respond_to? :list_change_log_entries + @list_change_log_entries = ::Gapic::Config::Method.new list_change_log_entries_config + get_change_log_entry_config = parent_rpcs.get_change_log_entry if parent_rpcs.respond_to? :get_change_log_entry + @get_change_log_entry = ::Gapic::Config::Method.new get_change_log_entry_config + list_skus_config = parent_rpcs.list_skus if parent_rpcs.respond_to? :list_skus + @list_skus = ::Gapic::Config::Method.new list_skus_config + get_sku_config = parent_rpcs.get_sku if parent_rpcs.respond_to? :get_sku + @get_sku = ::Gapic::Config::Method.new get_sku_config + list_zones_config = parent_rpcs.list_zones if parent_rpcs.respond_to? :list_zones + @list_zones = ::Gapic::Config::Method.new list_zones_config + get_zone_config = parent_rpcs.get_zone if parent_rpcs.respond_to? :get_zone + @get_zone = ::Gapic::Config::Method.new get_zone_config + create_zone_config = parent_rpcs.create_zone if parent_rpcs.respond_to? :create_zone + @create_zone = ::Gapic::Config::Method.new create_zone_config + update_zone_config = parent_rpcs.update_zone if parent_rpcs.respond_to? :update_zone + @update_zone = ::Gapic::Config::Method.new update_zone_config + delete_zone_config = parent_rpcs.delete_zone if parent_rpcs.respond_to? :delete_zone + @delete_zone = ::Gapic::Config::Method.new delete_zone_config + signal_zone_state_config = parent_rpcs.signal_zone_state if parent_rpcs.respond_to? :signal_zone_state + @signal_zone_state = ::Gapic::Config::Method.new signal_zone_state_config + request_order_date_change_config = parent_rpcs.request_order_date_change if parent_rpcs.respond_to? :request_order_date_change + @request_order_date_change = ::Gapic::Config::Method.new request_order_date_change_config + + yield self if block_given? + end + end + end + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb new file mode 100644 index 000000000000..f71ab8bc016f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "googleauth" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + # Credentials for the GDCHardwareManagement API. + class Credentials < ::Google::Auth::Credentials + self.scope = [ + "https://www.googleapis.com/auth/cloud-platform" + ] + self.env_vars = [ + "GOOGLE_CLOUD_CREDENTIALS", + "GOOGLE_CLOUD_KEYFILE", + "GCLOUD_KEYFILE", + "GOOGLE_CLOUD_CREDENTIALS_JSON", + "GOOGLE_CLOUD_KEYFILE_JSON", + "GCLOUD_KEYFILE_JSON" + ] + self.paths = [ + "~/.config/google_cloud/application_default_credentials.json" + ] + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb new file mode 100644 index 000000000000..284b8f8b9f8c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb @@ -0,0 +1,841 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/operation" +require "google/longrunning/operations_pb" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + # Service that implements Longrunning Operations API. + class Operations + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" + + # @private + attr_reader :operations_stub + + ## + # Configuration for the GDCHardwareManagement Operations API. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def self.configure + @configure ||= Operations::Configuration.new + yield @configure if block_given? + @configure + end + + ## + # Configure the GDCHardwareManagement Operations instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Operations.configure}. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @operations_stub.universe_domain + end + + ## + # Create a new Operations client object. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Operations::Configuration] + # + def initialize + # These require statements are intentionally placed here to initialize + # the gRPC module only when it's required. + # See https://github.com/googleapis/toolkit/issues/446 + require "gapic/grpc" + require "google/longrunning/operations_services_pb" + + # Create the configuration object + @config = Configuration.new Operations.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + credentials ||= Credentials.default scope: @config.scope + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_stub = ::Gapic::ServiceStub.new( + ::Google::Longrunning::Operations::Stub, + credentials: credentials, + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + channel_args: @config.channel_args, + interceptors: @config.interceptors, + channel_pool_config: @config.channel_pool + ) + + # Used by an LRO wrapper for some methods of this service + @operations_client = self + end + + # Service calls + + ## + # Lists operations that match the specified filter in the request. If the + # server doesn't support this method, it returns `UNIMPLEMENTED`. + # + # @overload list_operations(request, options = nil) + # Pass arguments to `list_operations` via a request object, either of type + # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::ListOperationsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload list_operations(name: nil, filter: nil, page_size: nil, page_token: nil, return_partial_success: nil) + # Pass arguments to `list_operations` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation's parent resource. + # @param filter [::String] + # The standard list filter. + # @param page_size [::Integer] + # The standard list page size. + # @param page_token [::String] + # The standard list page token. + # @param return_partial_success [::Boolean] + # When set to `true`, operations that are reachable are returned as normal, + # and those that are unreachable are returned in the + # [ListOperationsResponse.unreachable] field. + # + # This can only be `true` when reading across collections e.g. when `parent` + # is set to `"projects/example/locations/-"`. + # + # This field is not by default supported and will result in an + # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + # service or product specific documentation. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::PagedEnumerable<::Gapic::Operation>] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::PagedEnumerable<::Gapic::Operation>] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::ListOperationsRequest.new + # + # # Call the list_operations method. + # result = client.list_operations request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Longrunning::Operation. + # p item + # end + # + def list_operations request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::ListOperationsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.list_operations.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.list_operations.timeout, + metadata: metadata, + retry_policy: @config.rpcs.list_operations.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.call_rpc :list_operations, request, options: options do |response, operation| + wrap_lro_operation = ->(op_response) { ::Gapic::Operation.new op_response, @operations_client } + response = ::Gapic::PagedEnumerable.new @operations_stub, :list_operations, request, response, operation, options, format_resource: wrap_lro_operation + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the latest state of a long-running operation. Clients can use this + # method to poll the operation result at intervals as recommended by the API + # service. + # + # @overload get_operation(request, options = nil) + # Pass arguments to `get_operation` via a request object, either of type + # {::Google::Longrunning::GetOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::GetOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload get_operation(name: nil) + # Pass arguments to `get_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::GetOperationRequest.new + # + # # Call the get_operation method. + # result = client.get_operation request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def get_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::GetOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.get_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.get_operation.timeout, + metadata: metadata, + retry_policy: @config.rpcs.get_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.call_rpc :get_operation, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a long-running operation. This method indicates that the client is + # no longer interested in the operation result. It does not cancel the + # operation. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. + # + # @overload delete_operation(request, options = nil) + # Pass arguments to `delete_operation` via a request object, either of type + # {::Google::Longrunning::DeleteOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::DeleteOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload delete_operation(name: nil) + # Pass arguments to `delete_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be deleted. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Protobuf::Empty] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::DeleteOperationRequest.new + # + # # Call the delete_operation method. + # result = client.delete_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def delete_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::DeleteOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.delete_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.delete_operation.timeout, + metadata: metadata, + retry_policy: @config.rpcs.delete_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Starts asynchronous cancellation on a long-running operation. The server + # makes a best effort to cancel the operation, but success is not + # guaranteed. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. Clients can use + # Operations.GetOperation or + # other methods to check whether the cancellation succeeded or whether the + # operation completed despite cancellation. On successful cancellation, + # the operation is not deleted; instead, it becomes an operation with + # an {::Google::Longrunning::Operation#error Operation.error} value with a + # {::Google::Rpc::Status#code google.rpc.Status.code} of `1`, corresponding to + # `Code.CANCELLED`. + # + # @overload cancel_operation(request, options = nil) + # Pass arguments to `cancel_operation` via a request object, either of type + # {::Google::Longrunning::CancelOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::CancelOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload cancel_operation(name: nil) + # Pass arguments to `cancel_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be cancelled. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Google::Protobuf::Empty] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::CancelOperationRequest.new + # + # # Call the cancel_operation method. + # result = client.cancel_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def cancel_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::CancelOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.cancel_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + header_params = {} + if request.name + header_params["name"] = request.name + end + + request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") + metadata[:"x-goog-request-params"] ||= request_params_header + + options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout, + metadata: metadata, + retry_policy: @config.rpcs.cancel_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation| + yield response, operation if block_given? + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Waits until the specified long-running operation is done or reaches at most + # a specified timeout, returning the latest state. If the operation is + # already done, the latest state is immediately returned. If the timeout + # specified is greater than the default HTTP/RPC timeout, the HTTP/RPC + # timeout is used. If the server does not support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. + # Note that this method is on a best-effort basis. It may return the latest + # state before the specified timeout (including immediately), meaning even an + # immediate response is no guarantee that the operation is done. + # + # @overload wait_operation(request, options = nil) + # Pass arguments to `wait_operation` via a request object, either of type + # {::Google::Longrunning::WaitOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::WaitOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. + # + # @overload wait_operation(name: nil, timeout: nil) + # Pass arguments to `wait_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to wait on. + # @param timeout [::Google::Protobuf::Duration, ::Hash] + # The maximum duration to wait before timing out. If left blank, the wait + # will be at most the time permitted by the underlying HTTP/RPC protocol. + # If RPC context deadline is also specified, the shorter one will be used. + # + # @yield [response, operation] Access the result along with the RPC operation + # @yieldparam response [::Gapic::Operation] + # @yieldparam operation [::GRPC::ActiveCall::Operation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the RPC is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::WaitOperationRequest.new + # + # # Call the wait_operation method. + # result = client.wait_operation request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def wait_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::WaitOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + metadata = @config.rpcs.wait_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION + metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.wait_operation.timeout, + metadata: metadata, + retry_policy: @config.rpcs.wait_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation| + response = ::Gapic::Operation.new response, @operations_client, options: options + yield response, operation if block_given? + throw :response, response + end + rescue ::GRPC::BadStatus => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the Operations API. + # + # This class represents the configuration for Operations, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Longrunning::Operations::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_operations to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Longrunning::Operations::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Longrunning::Operations::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`GRPC::Core::Channel`) a gRPC channel with included credentials + # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object + # * (`nil`) indicating no credentials + # + # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials + # is deprecated. Providing an unvalidated credential configuration to + # Google APIs can compromise the security of your systems and data. + # + # @example + # + # # The recommended way to provide credentials is to use the `make_creds` method + # # on the appropriate credentials class for your environment. + # + # require "googleauth" + # + # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds( + # json_key_io: ::File.open("/path/to/keyfile.json") + # ) + # + # client = ::Google::Longrunning::Operations::Client.new do |config| + # config.credentials = credentials + # end + # + # @note Warning: If you accept a credential configuration (JSON file or Hash) from an + # external source for authentication to Google Cloud, you must validate it before + # providing it to a Google API client library. Providing an unvalidated credential + # configuration to Google APIs can compromise the security of your systems and data. + # For more information, refer to [Validate credential configurations from external + # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] channel_args + # Extra parameters passed to the gRPC channel. Note: this is ignored if a + # `GRPC::Core::Channel` object is provided as the credential. + # @return [::Hash] + # @!attribute [rw] interceptors + # An array of interceptors that are run before calls are executed. + # @return [::Array<::GRPC::ClientInterceptor>] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional gRPC headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # @!attribute [rw] logger + # A custom logger to use for request/response debug logging, or the value + # `:default` (the default) to construct a default logger, or `nil` to + # explicitly disable logging. + # @return [::Logger,:default,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] + allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC::Core::Channel + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil) + config_attr :interceptors, nil, ::Array, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + config_attr :logger, :default, ::Logger, nil, :default + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration for the channel pool + # @return [::Gapic::ServiceStub::ChannelPool::Configuration] + # + def channel_pool + @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new + end + + ## + # Configuration RPC class for the Operations API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_operations` + # @return [::Gapic::Config::Method] + # + attr_reader :list_operations + ## + # RPC-specific configuration for `get_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :get_operation + ## + # RPC-specific configuration for `delete_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_operation + ## + # RPC-specific configuration for `cancel_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :cancel_operation + ## + # RPC-specific configuration for `wait_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :wait_operation + + # @private + def initialize parent_rpcs = nil + list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations + @list_operations = ::Gapic::Config::Method.new list_operations_config + get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation + @get_operation = ::Gapic::Config::Method.new get_operation_config + delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation + @delete_operation = ::Gapic::Config::Method.new delete_operation_config + cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation + @cancel_operation = ::Gapic::Config::Method.new cancel_operation_config + wait_operation_config = parent_rpcs.wait_operation if parent_rpcs.respond_to? :wait_operation + @wait_operation = ::Gapic::Config::Method.new wait_operation_config + + yield self if block_given? + end + end + end + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb new file mode 100644 index 000000000000..37a35977c460 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb @@ -0,0 +1,208 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + # Path helper methods for the GDCHardwareManagement API. + module Paths + ## + # Create a fully-qualified ChangeLogEntry resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` + # + # @param project [String] + # @param location [String] + # @param order [String] + # @param change_log_entry [String] + # + # @return [::String] + def change_log_entry_path project:, location:, order:, change_log_entry: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" + + "projects/#{project}/locations/#{location}/orders/#{order}/changeLogEntries/#{change_log_entry}" + end + + ## + # Create a fully-qualified Comment resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # + # @param project [String] + # @param location [String] + # @param order [String] + # @param comment [String] + # + # @return [::String] + def comment_path project:, location:, order:, comment: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" + + "projects/#{project}/locations/#{location}/orders/#{order}/comments/#{comment}" + end + + ## + # Create a fully-qualified Hardware resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/hardware/{hardware}` + # + # @param project [String] + # @param location [String] + # @param hardware [String] + # + # @return [::String] + def hardware_path project:, location:, hardware: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/hardware/#{hardware}" + end + + ## + # Create a fully-qualified HardwareGroup resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # + # @param project [String] + # @param location [String] + # @param order [String] + # @param hardware_group [String] + # + # @return [::String] + def hardware_group_path project:, location:, order:, hardware_group: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" + + "projects/#{project}/locations/#{location}/orders/#{order}/hardwareGroups/#{hardware_group}" + end + + ## + # Create a fully-qualified Location resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}` + # + # @param project [String] + # @param location [String] + # + # @return [::String] + def location_path project:, location: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + + "projects/#{project}/locations/#{location}" + end + + ## + # Create a fully-qualified Order resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/orders/{order}` + # + # @param project [String] + # @param location [String] + # @param order [String] + # + # @return [::String] + def order_path project:, location:, order: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/orders/#{order}" + end + + ## + # Create a fully-qualified Site resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/sites/{site}` + # + # @param project [String] + # @param location [String] + # @param site [String] + # + # @return [::String] + def site_path project:, location:, site: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/sites/#{site}" + end + + ## + # Create a fully-qualified Sku resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/skus/{sku}` + # + # @param project [String] + # @param location [String] + # @param sku [String] + # + # @return [::String] + def sku_path project:, location:, sku: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/skus/#{sku}" + end + + ## + # Create a fully-qualified Zone resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/zones/{zone}` + # + # @param project [String] + # @param location [String] + # @param zone [String] + # + # @return [::String] + def zone_path project:, location:, zone: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/zones/#{zone}" + end + + extend self + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb new file mode 100644 index 000000000000..a6427b850375 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/rest" +require "gapic/config" +require "gapic/config/method" + +require "google/cloud/gdc_hardware_management/v1alpha/version" +require "google/cloud/gdc_hardware_management/v1alpha/bindings_override" + +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + ## + # The GDC Hardware Management service. + # + # To load this service and instantiate a REST client: + # + # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + module GDCHardwareManagement + # Client for the REST transport + module Rest + end + end + end + end + end +end + +helper_path = ::File.join __dir__, "rest", "helpers.rb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb new file mode 100644 index 000000000000..a682f54057ca --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb @@ -0,0 +1,4205 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/errors" +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub" +require "google/cloud/location/rest" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + module Rest + ## + # REST client for the GDCHardwareManagement service. + # + # The GDC Hardware Management service. + # + class Client + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" + + include Paths + + # @private + attr_reader :gdc_hardware_management_stub + + ## + # Configure the GDCHardwareManagement Client class. + # + # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration} + # for a description of the configuration fields. + # + # @example + # + # # Modify the configuration for all GDCHardwareManagement clients + # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.configure do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def self.configure + @configure ||= begin + namespace = ["Google", "Cloud", "GDCHardwareManagement", "V1alpha"] + parent_config = while namespace.any? + parent_name = namespace.join "::" + parent_const = const_get parent_name + break parent_const.configure if parent_const.respond_to? :configure + namespace.pop + end + default_config = Client::Configuration.new parent_config + + default_config.rpcs.list_orders.timeout = 60.0 + default_config.rpcs.list_orders.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_order.timeout = 60.0 + default_config.rpcs.get_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_order.timeout = 60.0 + + default_config.rpcs.update_order.timeout = 60.0 + default_config.rpcs.update_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_order.timeout = 60.0 + default_config.rpcs.delete_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.submit_order.timeout = 60.0 + default_config.rpcs.submit_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.cancel_order.timeout = 60.0 + default_config.rpcs.cancel_order.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_sites.timeout = 60.0 + default_config.rpcs.list_sites.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_site.timeout = 60.0 + default_config.rpcs.get_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_site.timeout = 60.0 + + default_config.rpcs.update_site.timeout = 60.0 + default_config.rpcs.update_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_site.timeout = 60.0 + default_config.rpcs.delete_site.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_hardware_groups.timeout = 60.0 + default_config.rpcs.list_hardware_groups.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_hardware_group.timeout = 60.0 + default_config.rpcs.get_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_hardware_group.timeout = 60.0 + + default_config.rpcs.update_hardware_group.timeout = 60.0 + default_config.rpcs.update_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_hardware_group.timeout = 60.0 + default_config.rpcs.delete_hardware_group.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_hardware.timeout = 60.0 + default_config.rpcs.list_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_hardware.timeout = 60.0 + default_config.rpcs.get_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_hardware.timeout = 60.0 + + default_config.rpcs.update_hardware.timeout = 60.0 + default_config.rpcs.update_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_hardware.timeout = 60.0 + default_config.rpcs.delete_hardware.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_comments.timeout = 60.0 + default_config.rpcs.list_comments.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_comment.timeout = 60.0 + default_config.rpcs.get_comment.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_comment.timeout = 60.0 + + default_config.rpcs.list_change_log_entries.timeout = 60.0 + default_config.rpcs.list_change_log_entries.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_change_log_entry.timeout = 60.0 + default_config.rpcs.get_change_log_entry.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_skus.timeout = 60.0 + default_config.rpcs.list_skus.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_sku.timeout = 60.0 + default_config.rpcs.get_sku.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.list_zones.timeout = 60.0 + default_config.rpcs.list_zones.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.get_zone.timeout = 60.0 + default_config.rpcs.get_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.create_zone.timeout = 60.0 + + default_config.rpcs.update_zone.timeout = 60.0 + default_config.rpcs.update_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config.rpcs.delete_zone.timeout = 60.0 + default_config.rpcs.delete_zone.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] + } + + default_config + end + yield @configure if block_given? + @configure + end + + ## + # Configure the GDCHardwareManagement Client instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Client.configure}. + # + # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration} + # for a description of the configuration fields. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @gdc_hardware_management_stub.universe_domain + end + + ## + # Create a new GDCHardwareManagement REST client object. + # + # @example + # + # # Create a client using the default configuration + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a client using a custom configuration + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the GDCHardwareManagement client. + # @yieldparam config [Client::Configuration] + # + def initialize + # Create the configuration object + @config = Configuration.new Client.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + # Use self-signed JWT if the endpoint is unchanged from default, + # but only if the default endpoint does not have a region prefix. + enable_self_signed_jwt = @config.endpoint.nil? || + (@config.endpoint == Configuration::DEFAULT_ENDPOINT && + !@config.endpoint.split(".").first.include?("-")) + credentials ||= Credentials.default scope: @config.scope, + enable_self_signed_jwt: enable_self_signed_jwt + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Operations.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @config.endpoint + config.universe_domain = @config.universe_domain + end + + @gdc_hardware_management_stub = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.new( + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + credentials: credentials, + logger: @config.logger + ) + + @gdc_hardware_management_stub.logger(stub: true)&.info do |entry| + entry.set_system_name + entry.set_service + entry.message = "Created client for #{entry.service}" + entry.set_credentials_fields credentials + entry.set "customEndpoint", @config.endpoint if @config.endpoint + entry.set "defaultTimeout", @config.timeout if @config.timeout + entry.set "quotaProject", @quota_project_id if @quota_project_id + end + + @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @gdc_hardware_management_stub.endpoint + config.universe_domain = @gdc_hardware_management_stub.universe_domain + config.bindings_override = @config.bindings_override + config.logger = @gdc_hardware_management_stub.logger if config.respond_to? :logger= + end + end + + ## + # Get the associated client for long-running operations. + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Operations] + # + attr_reader :operations_client + + ## + # Get the associated client for mix-in of the Locations. + # + # @return [Google::Cloud::Location::Locations::Rest::Client] + # + attr_reader :location_client + + ## + # The logger used for request/response debug logging. + # + # @return [Logger] + # + def logger + @gdc_hardware_management_stub.logger + end + + # Service calls + + ## + # Lists orders in a given project and location. + # + # @overload list_orders(request, options = nil) + # Pass arguments to `list_orders` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_orders(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_orders` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list orders in. + # Format: `projects/{project}/locations/{location}` + # + # To list orders across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new + # + # # Call the list_orders method. + # result = client.list_orders request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. + # p item + # end + # + def list_orders request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_orders.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_orders.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_orders.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_orders request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_orders, "orders", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of an order. + # + # @overload get_order(request, options = nil) + # Pass arguments to `get_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_order(name: nil) + # Pass arguments to `get_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. Name of the resource + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new + # + # # Call the get_order method. + # result = client.get_order request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. + # p result + # + def get_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_order request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new order in a given project and location. + # + # @overload create_order(request, options = nil) + # Pass arguments to `create_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_order(parent: nil, order_id: nil, order: nil, request_id: nil) + # Pass arguments to `create_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the order in. + # Format: `projects/{project}/locations/{location}` + # @param order_id [::String] + # Optional. ID used to uniquely identify the Order within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The order.name field in the request will be ignored. + # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] + # Required. The order to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new + # + # # Call the create_order method. + # result = client.create_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_order request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of an order. + # + # @overload update_order(request, options = nil) + # Pass arguments to `update_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload update_order(update_mask: nil, order: nil, request_id: nil) + # Pass arguments to `update_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Order to overwrite with this + # update. The fields specified in the update_mask are relative to the order, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] + # Required. The order to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new + # + # # Call the update_order method. + # result = client.update_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.update_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.update_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.update_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.update_order request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes an order. + # + # @overload delete_order(request, options = nil) + # Pass arguments to `delete_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_order(name: nil, request_id: nil, force: nil) + # Pass arguments to `delete_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param force [::Boolean] + # Optional. An option to delete any nested resources in the Order, such as a + # HardwareGroup. If true, any nested resources for this Order will also be + # deleted. Otherwise, the request will only succeed if the Order has no + # nested resources. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new + # + # # Call the delete_order method. + # result = client.delete_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.delete_order request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Submits an order. + # + # @overload submit_order(request, options = nil) + # Pass arguments to `submit_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload submit_order(name: nil, request_id: nil, type: nil) + # Pass arguments to `submit_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param type [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] + # Optional. Type of this request. If unset, the request type is assumed to be + # `INFO_PENDING`. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new + # + # # Call the submit_order method. + # result = client.submit_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def submit_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.submit_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.submit_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.submit_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.submit_order request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Cancels an order. + # + # @overload cancel_order(request, options = nil) + # Pass arguments to `cancel_order` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload cancel_order(name: nil, request_id: nil) + # Pass arguments to `cancel_order` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new + # + # # Call the cancel_order method. + # result = client.cancel_order request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def cancel_order request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.cancel_order.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.cancel_order.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.cancel_order.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.cancel_order request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists sites in a given project and location. + # + # @overload list_sites(request, options = nil) + # Pass arguments to `list_sites` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_sites(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_sites` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list sites in. + # Format: `projects/{project}/locations/{location}` + # + # To list sites across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new + # + # # Call the list_sites method. + # result = client.list_sites request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. + # p item + # end + # + def list_sites request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_sites.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_sites.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_sites.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_sites request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_sites, "sites", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a site. + # + # @overload get_site(request, options = nil) + # Pass arguments to `get_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_site(name: nil) + # Pass arguments to `get_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new + # + # # Call the get_site method. + # result = client.get_site request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. + # p result + # + def get_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_site.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_site request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new site in a given project and location. + # + # @overload create_site(request, options = nil) + # Pass arguments to `create_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_site(parent: nil, site_id: nil, site: nil, request_id: nil) + # Pass arguments to `create_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the site in. + # Format: `projects/{project}/locations/{location}` + # @param site_id [::String] + # Optional. ID used to uniquely identify the Site within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The site.name field in the request will be ignored. + # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] + # Required. The site to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new + # + # # Call the create_site method. + # result = client.create_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_site.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_site request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a site. + # + # @overload update_site(request, options = nil) + # Pass arguments to `update_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload update_site(update_mask: nil, site: nil, request_id: nil) + # Pass arguments to `update_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Site to overwrite with this + # update. The fields specified in the update_mask are relative to the site, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] + # Required. The site to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new + # + # # Call the update_site method. + # result = client.update_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.update_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.update_site.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.update_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.update_site request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a site. + # + # @overload delete_site(request, options = nil) + # Pass arguments to `delete_site` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_site(name: nil, request_id: nil) + # Pass arguments to `delete_site` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new + # + # # Call the delete_site method. + # result = client.delete_site request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_site request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_site.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_site.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_site.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.delete_site request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists hardware groups in a given order. + # + # @overload list_hardware_groups(request, options = nil) + # Pass arguments to `list_hardware_groups` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_hardware_groups(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_hardware_groups` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list hardware groups in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new + # + # # Call the list_hardware_groups method. + # result = client.list_hardware_groups request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + # p item + # end + # + def list_hardware_groups request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_hardware_groups.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_hardware_groups.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_hardware_groups.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_hardware_groups request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware_groups, "hardware_groups", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a hardware group. + # + # @overload get_hardware_group(request, options = nil) + # Pass arguments to `get_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_hardware_group(name: nil) + # Pass arguments to `get_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new + # + # # Call the get_hardware_group method. + # result = client.get_hardware_group request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + # p result + # + def get_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_hardware_group.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_hardware_group request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new hardware group in a given order. + # + # @overload create_hardware_group(request, options = nil) + # Pass arguments to `create_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_hardware_group(parent: nil, hardware_group_id: nil, hardware_group: nil, request_id: nil) + # Pass arguments to `create_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to create the hardware group in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param hardware_group_id [::String] + # Optional. ID used to uniquely identify the HardwareGroup within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware_group.name field in the request will be ignored. + # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] + # Required. The hardware group to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new + # + # # Call the create_hardware_group method. + # result = client.create_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_hardware_group.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_hardware_group request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a hardware group. + # + # @overload update_hardware_group(request, options = nil) + # Pass arguments to `update_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload update_hardware_group(update_mask: nil, hardware_group: nil, request_id: nil) + # Pass arguments to `update_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the HardwareGroup to overwrite + # with this update. The fields specified in the update_mask are relative to + # the hardware group, not the full request. A field will be overwritten if it + # is in the mask. If you don't provide a mask then all fields will be + # overwritten. + # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] + # Required. The hardware group to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new + # + # # Call the update_hardware_group method. + # result = client.update_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.update_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.update_hardware_group.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.update_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.update_hardware_group request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a hardware group. + # + # @overload delete_hardware_group(request, options = nil) + # Pass arguments to `delete_hardware_group` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_hardware_group(name: nil, request_id: nil) + # Pass arguments to `delete_hardware_group` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new + # + # # Call the delete_hardware_group method. + # result = client.delete_hardware_group request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_hardware_group request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_hardware_group.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_hardware_group.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_hardware_group.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.delete_hardware_group request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists hardware in a given project and location. + # + # @overload list_hardware(request, options = nil) + # Pass arguments to `list_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_hardware(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list hardware in. + # Format: `projects/{project}/locations/{location}` + # + # To list hardware across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new + # + # # Call the list_hardware method. + # result = client.list_hardware request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + # p item + # end + # + def list_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_hardware.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_hardware request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware, "hardware", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets hardware details. + # + # @overload get_hardware(request, options = nil) + # Pass arguments to `get_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_hardware(name: nil) + # Pass arguments to `get_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new + # + # # Call the get_hardware method. + # result = client.get_hardware request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + # p result + # + def get_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_hardware.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_hardware request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates new hardware in a given project and location. + # + # @overload create_hardware(request, options = nil) + # Pass arguments to `create_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_hardware(parent: nil, hardware_id: nil, hardware: nil) + # Pass arguments to `create_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create hardware in. + # Format: `projects/{project}/locations/{location}` + # @param hardware_id [::String] + # Optional. ID used to uniquely identify the Hardware within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware.name field in the request will be ignored. + # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] + # Required. The resource to create. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new + # + # # Call the create_hardware method. + # result = client.create_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_hardware.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_hardware request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates hardware parameters. + # + # @overload update_hardware(request, options = nil) + # Pass arguments to `update_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload update_hardware(update_mask: nil, hardware: nil, request_id: nil) + # Pass arguments to `update_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Hardware to overwrite with + # this update. The fields specified in the update_mask are relative to the + # hardware, not the full request. A field will be overwritten if it is in the + # mask. If you don't provide a mask then all fields will be overwritten. + # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] + # Required. The hardware to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new + # + # # Call the update_hardware method. + # result = client.update_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.update_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.update_hardware.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.update_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.update_hardware request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes hardware. + # + # @overload delete_hardware(request, options = nil) + # Pass arguments to `delete_hardware` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_hardware(name: nil, request_id: nil) + # Pass arguments to `delete_hardware` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new + # + # # Call the delete_hardware method. + # result = client.delete_hardware request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_hardware request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_hardware.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_hardware.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_hardware.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.delete_hardware request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the comments on an order. + # + # @overload list_comments(request, options = nil) + # Pass arguments to `list_comments` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_comments(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_comments` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list comments on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new + # + # # Call the list_comments method. + # result = client.list_comments request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p item + # end + # + def list_comments request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_comments.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_comments.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_comments.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_comments request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_comments, "comments", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the content of a comment. + # + # @overload get_comment(request, options = nil) + # Pass arguments to `get_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_comment(name: nil) + # Pass arguments to `get_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new + # + # # Call the get_comment method. + # result = client.get_comment request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p result + # + def get_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_comment.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_comment request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new comment on an order. + # + # @overload create_comment(request, options = nil) + # Pass arguments to `create_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_comment(parent: nil, comment_id: nil, comment: nil, request_id: nil) + # Pass arguments to `create_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to create the comment on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param comment_id [::String] + # Optional. ID used to uniquely identify the Comment within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The comment.name field in the request will be ignored. + # @param comment [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment, ::Hash] + # Required. The comment to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new + # + # # Call the create_comment method. + # result = client.create_comment request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_comment.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_comment request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Record Action on a Comment. If the Action specified in the request is READ, + # the viewed time in the comment is set to the time the request was received. + # If the comment is already marked as read, subsequent calls will be ignored. + # If the Action is UNREAD, the viewed time is cleared from the comment. + # + # @overload record_action_on_comment(request, options = nil) + # Pass arguments to `record_action_on_comment` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload record_action_on_comment(name: nil, action_type: nil) + # Pass arguments to `record_action_on_comment` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # @param action_type [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] + # Required. The action type of the recorded action. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new + # + # # Call the record_action_on_comment method. + # result = client.record_action_on_comment request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + # p result + # + def record_action_on_comment request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.record_action_on_comment.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.record_action_on_comment.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.record_action_on_comment.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.record_action_on_comment request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the changes made to an order. + # + # @overload list_change_log_entries(request, options = nil) + # Pass arguments to `list_change_log_entries` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_change_log_entries(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_change_log_entries` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The order to list change log entries for. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new + # + # # Call the list_change_log_entries method. + # result = client.list_change_log_entries request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + # p item + # end + # + def list_change_log_entries request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_change_log_entries.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_change_log_entries.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_change_log_entries.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_change_log_entries request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_change_log_entries, "change_log_entries", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a change to an order. + # + # @overload get_change_log_entry(request, options = nil) + # Pass arguments to `get_change_log_entry` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_change_log_entry(name: nil) + # Pass arguments to `get_change_log_entry` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the change log entry. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new + # + # # Call the get_change_log_entry method. + # result = client.get_change_log_entry request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + # p result + # + def get_change_log_entry request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_change_log_entry.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_change_log_entry.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_change_log_entry.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_change_log_entry request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists SKUs for a given project and location. + # + # @overload list_skus(request, options = nil) + # Pass arguments to `list_skus` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_skus(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_skus` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list SKUs in. + # Format: `projects/{project}/locations/{location}` + # + # To list SKUs across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new + # + # # Call the list_skus method. + # result = client.list_skus request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + # p item + # end + # + def list_skus request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_skus.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_skus.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_skus.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_skus request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_skus, "skus", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of an SKU. + # + # @overload get_sku(request, options = nil) + # Pass arguments to `get_sku` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_sku(name: nil) + # Pass arguments to `get_sku` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the SKU. + # Format: `projects/{project}/locations/{location}/skus/{sku}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new + # + # # Call the get_sku method. + # result = client.get_sku request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + # p result + # + def get_sku request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_sku.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_sku.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_sku.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_sku request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists zones in a given project and location. + # + # @overload list_zones(request, options = nil) + # Pass arguments to `list_zones` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_zones(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_zones` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to list zones in. + # Format: `projects/{project}/locations/{location}` + # + # To list zones across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @param page_size [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @param order_by [::String] + # Optional. Hint for how to order the results. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new + # + # # Call the list_zones method. + # result = client.list_zones request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + # p item + # end + # + def list_zones request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_zones.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_zones.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_zones.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.list_zones request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_zones, "zones", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a zone. + # + # @overload get_zone(request, options = nil) + # Pass arguments to `get_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_zone(name: nil) + # Pass arguments to `get_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new + # + # # Call the get_zone method. + # result = client.get_zone request + # + # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + # p result + # + def get_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_zone.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.get_zone request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new zone in a given project and location. + # + # @overload create_zone(request, options = nil) + # Pass arguments to `create_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_zone(parent: nil, zone_id: nil, zone: nil, request_id: nil) + # Pass arguments to `create_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The project and location to create the zone in. + # Format: `projects/{project}/locations/{location}` + # @param zone_id [::String] + # Optional. ID used to uniquely identify the Zone within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The zone.name field in the request will be ignored. + # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] + # Required. The zone to create. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new + # + # # Call the create_zone method. + # result = client.create_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_zone.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.create_zone request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the parameters of a zone. + # + # @overload update_zone(request, options = nil) + # Pass arguments to `update_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload update_zone(update_mask: nil, zone: nil, request_id: nil) + # Pass arguments to `update_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] + # Required. A mask to specify the fields in the Zone to overwrite with this + # update. The fields specified in the update_mask are relative to the zone, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] + # Required. The zone to update. + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new + # + # # Call the update_zone method. + # result = client.update_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def update_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.update_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.update_zone.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.update_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.update_zone request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a zone. + # + # @overload delete_zone(request, options = nil) + # Pass arguments to `delete_zone` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_zone(name: nil, request_id: nil) + # Pass arguments to `delete_zone` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new + # + # # Call the delete_zone method. + # result = client.delete_zone request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_zone request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_zone.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_zone.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_zone.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.delete_zone request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Signals the state of a zone. + # + # @overload signal_zone_state(request, options = nil) + # Pass arguments to `signal_zone_state` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload signal_zone_state(name: nil, request_id: nil, state_signal: nil, provisioning_state_signal: nil, step: nil, details: nil) + # Pass arguments to `signal_zone_state` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @param request_id [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @param state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] + # Optional. The state signal to send for this zone. Either state_signal or + # provisioning_state_signal must be set, but not both. + # @param provisioning_state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] + # Optional. The provisioning state signal to send for this zone. Either + # state_signal or provisioning_state_signal must be set, but not both. + # @param step [::String] + # Optional. The step being executed. Provides a finer grained status when the + # state_signal is FACTORY_TURNUP_CHECKS_STARTED or + # FACTORY_TURNUP_CHECKS_FAILED. + # @param details [::String] + # Optional. Additional details, such as an error message when state_signal is + # FACTORY_TURNUP_CHECKS_FAILED. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new + # + # # Call the signal_zone_state method. + # result = client.signal_zone_state request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def signal_zone_state request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.signal_zone_state.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.signal_zone_state.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.signal_zone_state.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.signal_zone_state request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Updates the requested date change of a single Order. + # + # @overload request_order_date_change(request, options = nil) + # Pass arguments to `request_order_date_change` via a request object, either of type + # {::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload request_order_date_change(name: nil, requested_date: nil) + # Pass arguments to `request_order_date_change` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the order to update. + # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} + # @param requested_date [::Google::Type::Date, ::Hash] + # Required. The date to which the customer or Google wants to set the + # scheduled installation date. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/gdc_hardware_management/v1alpha" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new + # + # # Call the request_order_date_change method. + # result = client.request_order_date_change request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def request_order_date_change request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.request_order_date_change.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.request_order_date_change.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.request_order_date_change.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @gdc_hardware_management_stub.request_order_date_change request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the GDCHardwareManagement REST API. + # + # This class represents the configuration for GDCHardwareManagement REST, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_orders to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_orders.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_orders.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`String`) The path to a service account key file in JSON format + # * (`Hash`) A service account key as a Hash + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`nil`) indicating no credentials + # + # Warning: If you accept a credential configuration (JSON file or Hash) from an + # external source for authentication to Google Cloud, you must validate it before + # providing it to a Google API client library. Providing an unvalidated credential + # configuration to Google APIs can compromise the security of your systems and data. + # For more information, refer to [Validate credential configurations from external + # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # @!attribute [rw] logger + # A custom logger to use for request/response debug logging, or the value + # `:default` (the default) to construct a default logger, or `nil` to + # explicitly disable logging. + # @return [::Logger,:default,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + + # @private + # Overrides for http bindings for the RPCs of this service + # are only used when this service is used as mixin, and only + # by the host service. + # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}] + config_attr :bindings_override, {}, ::Hash, nil + config_attr :logger, :default, ::Logger, nil, :default + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration RPC class for the GDCHardwareManagement API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_orders` + # @return [::Gapic::Config::Method] + # + attr_reader :list_orders + ## + # RPC-specific configuration for `get_order` + # @return [::Gapic::Config::Method] + # + attr_reader :get_order + ## + # RPC-specific configuration for `create_order` + # @return [::Gapic::Config::Method] + # + attr_reader :create_order + ## + # RPC-specific configuration for `update_order` + # @return [::Gapic::Config::Method] + # + attr_reader :update_order + ## + # RPC-specific configuration for `delete_order` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_order + ## + # RPC-specific configuration for `submit_order` + # @return [::Gapic::Config::Method] + # + attr_reader :submit_order + ## + # RPC-specific configuration for `cancel_order` + # @return [::Gapic::Config::Method] + # + attr_reader :cancel_order + ## + # RPC-specific configuration for `list_sites` + # @return [::Gapic::Config::Method] + # + attr_reader :list_sites + ## + # RPC-specific configuration for `get_site` + # @return [::Gapic::Config::Method] + # + attr_reader :get_site + ## + # RPC-specific configuration for `create_site` + # @return [::Gapic::Config::Method] + # + attr_reader :create_site + ## + # RPC-specific configuration for `update_site` + # @return [::Gapic::Config::Method] + # + attr_reader :update_site + ## + # RPC-specific configuration for `delete_site` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_site + ## + # RPC-specific configuration for `list_hardware_groups` + # @return [::Gapic::Config::Method] + # + attr_reader :list_hardware_groups + ## + # RPC-specific configuration for `get_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :get_hardware_group + ## + # RPC-specific configuration for `create_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :create_hardware_group + ## + # RPC-specific configuration for `update_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :update_hardware_group + ## + # RPC-specific configuration for `delete_hardware_group` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_hardware_group + ## + # RPC-specific configuration for `list_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :list_hardware + ## + # RPC-specific configuration for `get_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :get_hardware + ## + # RPC-specific configuration for `create_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :create_hardware + ## + # RPC-specific configuration for `update_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :update_hardware + ## + # RPC-specific configuration for `delete_hardware` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_hardware + ## + # RPC-specific configuration for `list_comments` + # @return [::Gapic::Config::Method] + # + attr_reader :list_comments + ## + # RPC-specific configuration for `get_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :get_comment + ## + # RPC-specific configuration for `create_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :create_comment + ## + # RPC-specific configuration for `record_action_on_comment` + # @return [::Gapic::Config::Method] + # + attr_reader :record_action_on_comment + ## + # RPC-specific configuration for `list_change_log_entries` + # @return [::Gapic::Config::Method] + # + attr_reader :list_change_log_entries + ## + # RPC-specific configuration for `get_change_log_entry` + # @return [::Gapic::Config::Method] + # + attr_reader :get_change_log_entry + ## + # RPC-specific configuration for `list_skus` + # @return [::Gapic::Config::Method] + # + attr_reader :list_skus + ## + # RPC-specific configuration for `get_sku` + # @return [::Gapic::Config::Method] + # + attr_reader :get_sku + ## + # RPC-specific configuration for `list_zones` + # @return [::Gapic::Config::Method] + # + attr_reader :list_zones + ## + # RPC-specific configuration for `get_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :get_zone + ## + # RPC-specific configuration for `create_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :create_zone + ## + # RPC-specific configuration for `update_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :update_zone + ## + # RPC-specific configuration for `delete_zone` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_zone + ## + # RPC-specific configuration for `signal_zone_state` + # @return [::Gapic::Config::Method] + # + attr_reader :signal_zone_state + ## + # RPC-specific configuration for `request_order_date_change` + # @return [::Gapic::Config::Method] + # + attr_reader :request_order_date_change + + # @private + def initialize parent_rpcs = nil + list_orders_config = parent_rpcs.list_orders if parent_rpcs.respond_to? :list_orders + @list_orders = ::Gapic::Config::Method.new list_orders_config + get_order_config = parent_rpcs.get_order if parent_rpcs.respond_to? :get_order + @get_order = ::Gapic::Config::Method.new get_order_config + create_order_config = parent_rpcs.create_order if parent_rpcs.respond_to? :create_order + @create_order = ::Gapic::Config::Method.new create_order_config + update_order_config = parent_rpcs.update_order if parent_rpcs.respond_to? :update_order + @update_order = ::Gapic::Config::Method.new update_order_config + delete_order_config = parent_rpcs.delete_order if parent_rpcs.respond_to? :delete_order + @delete_order = ::Gapic::Config::Method.new delete_order_config + submit_order_config = parent_rpcs.submit_order if parent_rpcs.respond_to? :submit_order + @submit_order = ::Gapic::Config::Method.new submit_order_config + cancel_order_config = parent_rpcs.cancel_order if parent_rpcs.respond_to? :cancel_order + @cancel_order = ::Gapic::Config::Method.new cancel_order_config + list_sites_config = parent_rpcs.list_sites if parent_rpcs.respond_to? :list_sites + @list_sites = ::Gapic::Config::Method.new list_sites_config + get_site_config = parent_rpcs.get_site if parent_rpcs.respond_to? :get_site + @get_site = ::Gapic::Config::Method.new get_site_config + create_site_config = parent_rpcs.create_site if parent_rpcs.respond_to? :create_site + @create_site = ::Gapic::Config::Method.new create_site_config + update_site_config = parent_rpcs.update_site if parent_rpcs.respond_to? :update_site + @update_site = ::Gapic::Config::Method.new update_site_config + delete_site_config = parent_rpcs.delete_site if parent_rpcs.respond_to? :delete_site + @delete_site = ::Gapic::Config::Method.new delete_site_config + list_hardware_groups_config = parent_rpcs.list_hardware_groups if parent_rpcs.respond_to? :list_hardware_groups + @list_hardware_groups = ::Gapic::Config::Method.new list_hardware_groups_config + get_hardware_group_config = parent_rpcs.get_hardware_group if parent_rpcs.respond_to? :get_hardware_group + @get_hardware_group = ::Gapic::Config::Method.new get_hardware_group_config + create_hardware_group_config = parent_rpcs.create_hardware_group if parent_rpcs.respond_to? :create_hardware_group + @create_hardware_group = ::Gapic::Config::Method.new create_hardware_group_config + update_hardware_group_config = parent_rpcs.update_hardware_group if parent_rpcs.respond_to? :update_hardware_group + @update_hardware_group = ::Gapic::Config::Method.new update_hardware_group_config + delete_hardware_group_config = parent_rpcs.delete_hardware_group if parent_rpcs.respond_to? :delete_hardware_group + @delete_hardware_group = ::Gapic::Config::Method.new delete_hardware_group_config + list_hardware_config = parent_rpcs.list_hardware if parent_rpcs.respond_to? :list_hardware + @list_hardware = ::Gapic::Config::Method.new list_hardware_config + get_hardware_config = parent_rpcs.get_hardware if parent_rpcs.respond_to? :get_hardware + @get_hardware = ::Gapic::Config::Method.new get_hardware_config + create_hardware_config = parent_rpcs.create_hardware if parent_rpcs.respond_to? :create_hardware + @create_hardware = ::Gapic::Config::Method.new create_hardware_config + update_hardware_config = parent_rpcs.update_hardware if parent_rpcs.respond_to? :update_hardware + @update_hardware = ::Gapic::Config::Method.new update_hardware_config + delete_hardware_config = parent_rpcs.delete_hardware if parent_rpcs.respond_to? :delete_hardware + @delete_hardware = ::Gapic::Config::Method.new delete_hardware_config + list_comments_config = parent_rpcs.list_comments if parent_rpcs.respond_to? :list_comments + @list_comments = ::Gapic::Config::Method.new list_comments_config + get_comment_config = parent_rpcs.get_comment if parent_rpcs.respond_to? :get_comment + @get_comment = ::Gapic::Config::Method.new get_comment_config + create_comment_config = parent_rpcs.create_comment if parent_rpcs.respond_to? :create_comment + @create_comment = ::Gapic::Config::Method.new create_comment_config + record_action_on_comment_config = parent_rpcs.record_action_on_comment if parent_rpcs.respond_to? :record_action_on_comment + @record_action_on_comment = ::Gapic::Config::Method.new record_action_on_comment_config + list_change_log_entries_config = parent_rpcs.list_change_log_entries if parent_rpcs.respond_to? :list_change_log_entries + @list_change_log_entries = ::Gapic::Config::Method.new list_change_log_entries_config + get_change_log_entry_config = parent_rpcs.get_change_log_entry if parent_rpcs.respond_to? :get_change_log_entry + @get_change_log_entry = ::Gapic::Config::Method.new get_change_log_entry_config + list_skus_config = parent_rpcs.list_skus if parent_rpcs.respond_to? :list_skus + @list_skus = ::Gapic::Config::Method.new list_skus_config + get_sku_config = parent_rpcs.get_sku if parent_rpcs.respond_to? :get_sku + @get_sku = ::Gapic::Config::Method.new get_sku_config + list_zones_config = parent_rpcs.list_zones if parent_rpcs.respond_to? :list_zones + @list_zones = ::Gapic::Config::Method.new list_zones_config + get_zone_config = parent_rpcs.get_zone if parent_rpcs.respond_to? :get_zone + @get_zone = ::Gapic::Config::Method.new get_zone_config + create_zone_config = parent_rpcs.create_zone if parent_rpcs.respond_to? :create_zone + @create_zone = ::Gapic::Config::Method.new create_zone_config + update_zone_config = parent_rpcs.update_zone if parent_rpcs.respond_to? :update_zone + @update_zone = ::Gapic::Config::Method.new update_zone_config + delete_zone_config = parent_rpcs.delete_zone if parent_rpcs.respond_to? :delete_zone + @delete_zone = ::Gapic::Config::Method.new delete_zone_config + signal_zone_state_config = parent_rpcs.signal_zone_state if parent_rpcs.respond_to? :signal_zone_state + @signal_zone_state = ::Gapic::Config::Method.new signal_zone_state_config + request_order_date_change_config = parent_rpcs.request_order_date_change if parent_rpcs.respond_to? :request_order_date_change + @request_order_date_change = ::Gapic::Config::Method.new request_order_date_change_config + + yield self if block_given? + end + end + end + end + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb new file mode 100644 index 000000000000..0fd6460e36ea --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb @@ -0,0 +1,925 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/operation" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + module Rest + # Service that implements Longrunning Operations API. + class Operations + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" + + # @private + attr_reader :operations_stub + + ## + # Configuration for the GDCHardwareManagement Operations API. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def self.configure + @configure ||= Operations::Configuration.new + yield @configure if block_given? + @configure + end + + ## + # Configure the GDCHardwareManagement Operations instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Operations.configure}. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @operations_stub.universe_domain + end + + ## + # Create a new Operations client object. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Operations::Configuration] + # + def initialize + # Create the configuration object + @config = Configuration.new Operations.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + credentials ||= Credentials.default scope: @config.scope + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_stub = OperationsServiceStub.new( + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + credentials: credentials + ) + + # Used by an LRO wrapper for some methods of this service + @operations_client = self + end + + # Service calls + + ## + # Lists operations that match the specified filter in the request. If the + # server doesn't support this method, it returns `UNIMPLEMENTED`. + # + # @overload list_operations(request, options = nil) + # Pass arguments to `list_operations` via a request object, either of type + # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::ListOperationsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_operations(name: nil, filter: nil, page_size: nil, page_token: nil, return_partial_success: nil) + # Pass arguments to `list_operations` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation's parent resource. + # @param filter [::String] + # The standard list filter. + # @param page_size [::Integer] + # The standard list page size. + # @param page_token [::String] + # The standard list page token. + # @param return_partial_success [::Boolean] + # When set to `true`, operations that are reachable are returned as normal, + # and those that are unreachable are returned in the + # [ListOperationsResponse.unreachable] field. + # + # This can only be `true` when reading across collections e.g. when `parent` + # is set to `"projects/example/locations/-"`. + # + # This field is not by default supported and will result in an + # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + # service or product specific documentation. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::ListOperationsRequest.new + # + # # Call the list_operations method. + # result = client.list_operations request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Longrunning::Operation. + # p item + # end + # + def list_operations request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::ListOperationsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_operations.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_operations.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_operations.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.list_operations request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @operations_stub, :list_operations, "operations", request, result, options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the latest state of a long-running operation. Clients can use this + # method to poll the operation result at intervals as recommended by the API + # service. + # + # @overload get_operation(request, options = nil) + # Pass arguments to `get_operation` via a request object, either of type + # {::Google::Longrunning::GetOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::GetOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_operation(name: nil) + # Pass arguments to `get_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::GetOperationRequest.new + # + # # Call the get_operation method. + # result = client.get_operation request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def get_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::GetOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.get_operation request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + throw :response, result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a long-running operation. This method indicates that the client is + # no longer interested in the operation result. It does not cancel the + # operation. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. + # + # @overload delete_operation(request, options = nil) + # Pass arguments to `delete_operation` via a request object, either of type + # {::Google::Longrunning::DeleteOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::DeleteOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_operation(name: nil) + # Pass arguments to `delete_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be deleted. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::DeleteOperationRequest.new + # + # # Call the delete_operation method. + # result = client.delete_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def delete_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::DeleteOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.delete_operation request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Starts asynchronous cancellation on a long-running operation. The server + # makes a best effort to cancel the operation, but success is not + # guaranteed. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. Clients can use + # Operations.GetOperation or + # other methods to check whether the cancellation succeeded or whether the + # operation completed despite cancellation. On successful cancellation, + # the operation is not deleted; instead, it becomes an operation with + # an {::Google::Longrunning::Operation#error Operation.error} value with a + # {::Google::Rpc::Status#code google.rpc.Status.code} of `1`, corresponding to + # `Code.CANCELLED`. + # + # @overload cancel_operation(request, options = nil) + # Pass arguments to `cancel_operation` via a request object, either of type + # {::Google::Longrunning::CancelOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::CancelOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload cancel_operation(name: nil) + # Pass arguments to `cancel_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be cancelled. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::CancelOperationRequest.new + # + # # Call the cancel_operation method. + # result = client.cancel_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def cancel_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::CancelOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.cancel_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.cancel_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.cancel_operation request, options do |result, operation| + yield result, operation if block_given? + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the Operations REST API. + # + # This class represents the configuration for Operations REST, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Longrunning::Operations::Rest::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_operations to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Longrunning::Operations::Rest::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Longrunning::Operations::Rest::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`String`) The path to a service account key file in JSON format + # * (`Hash`) A service account key as a Hash + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`nil`) indicating no credentials + # + # Warning: If you accept a credential configuration (JSON file or Hash) from an + # external source for authentication to Google Cloud, you must validate it before + # providing it to a Google API client library. Providing an unvalidated credential + # configuration to Google APIs can compromise the security of your systems and data. + # For more information, refer to [Validate credential configurations from external + # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # @!attribute [rw] logger + # A custom logger to use for request/response debug logging, or the value + # `:default` (the default) to construct a default logger, or `nil` to + # explicitly disable logging. + # @return [::Logger,:default,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + config_attr :logger, :default, ::Logger, nil, :default + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration RPC class for the Operations API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_operations` + # @return [::Gapic::Config::Method] + # + attr_reader :list_operations + ## + # RPC-specific configuration for `get_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :get_operation + ## + # RPC-specific configuration for `delete_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_operation + ## + # RPC-specific configuration for `cancel_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :cancel_operation + + # @private + def initialize parent_rpcs = nil + list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations + @list_operations = ::Gapic::Config::Method.new list_operations_config + get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation + @get_operation = ::Gapic::Config::Method.new get_operation_config + delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation + @delete_operation = ::Gapic::Config::Method.new delete_operation_config + cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation + @cancel_operation = ::Gapic::Config::Method.new cancel_operation_config + + yield self if block_given? + end + end + end + end + + ## + # @private + # REST service stub for the Longrunning Operations API. + # Service stub contains baseline method implementations + # including transcoding, making the REST call, and deserialing the response. + class OperationsServiceStub + def initialize endpoint:, endpoint_template:, universe_domain:, credentials: + # These require statements are intentionally placed here to initialize + # the REST modules only when it's required. + require "gapic/rest" + + @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, + endpoint_template: endpoint_template, + universe_domain: universe_domain, + credentials: credentials + end + + ## + # Baseline implementation for the list_operations REST call + # + # @param request_pb [::Google::Longrunning::ListOperationsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::ListOperationsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::ListOperationsResponse] + # A result object deserialized from the server's reply + def list_operations request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_list_operations_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_operations", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::ListOperationsResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_operation REST call + # + # @param request_pb [::Google::Longrunning::GetOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def get_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_get_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_operation", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_operation REST call + # + # @param request_pb [::Google::Longrunning::DeleteOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # A result object deserialized from the server's reply + def delete_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_delete_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_operation", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the cancel_operation REST call + # + # @param request_pb [::Google::Longrunning::CancelOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # A result object deserialized from the server's reply + def cancel_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_cancel_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "cancel_operation", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # @private + # + # GRPC transcoding helper method for the list_operations REST call + # + # @param request_pb [::Google::Longrunning::ListOperationsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_operations_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}/operations", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_operation REST call + # + # @param request_pb [::Google::Longrunning::GetOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_operation REST call + # + # @param request_pb [::Google::Longrunning::DeleteOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the cancel_operation REST call + # + # @param request_pb [::Google::Longrunning::CancelOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_cancel_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:cancel", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + end + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb new file mode 100644 index 000000000000..0f1cf309a507 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb @@ -0,0 +1,2354 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + module Rest + ## + # REST service stub for the GDCHardwareManagement service. + # Service stub contains baseline method implementations + # including transcoding, making the REST call, and deserialing the response. + # + class ServiceStub + # @private + def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger: + # These require statements are intentionally placed here to initialize + # the REST modules only when it's required. + require "gapic/rest" + + @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, + endpoint_template: endpoint_template, + universe_domain: universe_domain, + credentials: credentials, + numeric_enums: true, + service_name: self.class, + raise_faraday_errors: false, + logger: logger + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @client_stub.universe_domain + end + + ## + # The effective endpoint + # + # @return [String] + # + def endpoint + @client_stub.endpoint + end + + ## + # The logger used for request/response debug logging. + # + # @return [Logger] + # + def logger stub: false + stub ? @client_stub.stub_logger : @client_stub.logger + end + + ## + # Baseline implementation for the list_orders REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse] + # A result object deserialized from the server's reply + def list_orders request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_orders_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_orders", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # A result object deserialized from the server's reply + def get_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the update_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def update_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_update_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "update_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the submit_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def submit_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_submit_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "submit_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the cancel_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def cancel_order request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_cancel_order_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "cancel_order", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_sites REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse] + # A result object deserialized from the server's reply + def list_sites request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_sites_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_sites", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # A result object deserialized from the server's reply + def get_site request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_site_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_site", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_site request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_site_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_site", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the update_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def update_site request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_update_site_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "update_site", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_site request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_site_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_site", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_hardware_groups REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse] + # A result object deserialized from the server's reply + def list_hardware_groups request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_hardware_groups_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_hardware_groups", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # A result object deserialized from the server's reply + def get_hardware_group request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_hardware_group_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_hardware_group", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_hardware_group request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_hardware_group_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_hardware_group", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the update_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def update_hardware_group request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_update_hardware_group_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "update_hardware_group", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_hardware_group request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_hardware_group_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_hardware_group", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse] + # A result object deserialized from the server's reply + def list_hardware request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_hardware_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_hardware", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # A result object deserialized from the server's reply + def get_hardware request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_hardware_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_hardware", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_hardware request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_hardware_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_hardware", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the update_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def update_hardware request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_update_hardware_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "update_hardware", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_hardware request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_hardware_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_hardware", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_comments REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse] + # A result object deserialized from the server's reply + def list_comments request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_comments_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_comments", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # A result object deserialized from the server's reply + def get_comment request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_comment_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_comment", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_comment request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_comment_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_comment", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the record_action_on_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # A result object deserialized from the server's reply + def record_action_on_comment request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_record_action_on_comment_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "record_action_on_comment", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_change_log_entries REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse] + # A result object deserialized from the server's reply + def list_change_log_entries request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_change_log_entries_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_change_log_entries", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_change_log_entry REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] + # A result object deserialized from the server's reply + def get_change_log_entry request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_change_log_entry_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_change_log_entry", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_skus REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse] + # A result object deserialized from the server's reply + def list_skus request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_skus_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_skus", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_sku REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] + # A result object deserialized from the server's reply + def get_sku request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_sku_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_sku", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the list_zones REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse] + # A result object deserialized from the server's reply + def list_zones request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_zones_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "list_zones", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the get_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # A result object deserialized from the server's reply + def get_zone request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_zone_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "get_zone", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the create_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_zone request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_zone_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "create_zone", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the update_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def update_zone request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_update_zone_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "update_zone", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the delete_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_zone request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_zone_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "delete_zone", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the signal_zone_state REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def signal_zone_state request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_signal_zone_state_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "signal_zone_state", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # Baseline implementation for the request_order_date_change REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def request_order_date_change request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_request_order_date_change_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + method_name: "request_order_date_change", + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + catch :response do + yield result, operation if block_given? + result + end + end + + ## + # @private + # + # GRPC transcoding helper method for the list_orders REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_orders_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/orders", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/orders", + body: "order", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the update_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_update_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :patch, + uri_template: "/v1alpha/{order.name}", + body: "order", + matches: [ + ["order.name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the submit_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_submit_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:submit", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the cancel_order REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_cancel_order_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:cancel", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_sites REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_sites_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/sites", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_site_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_site_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/sites", + body: "site", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the update_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_update_site_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :patch, + uri_template: "/v1alpha/{site.name}", + body: "site", + matches: [ + ["site.name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_site REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_site_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_hardware_groups REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_hardware_groups_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/hardwareGroups", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_hardware_group_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_hardware_group_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/hardwareGroups", + body: "hardware_group", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the update_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_update_hardware_group_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :patch, + uri_template: "/v1alpha/{hardware_group.name}", + body: "hardware_group", + matches: [ + ["hardware_group.name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_hardware_group REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_hardware_group_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_hardware_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/hardware", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_hardware_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_hardware_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/hardware", + body: "hardware", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the update_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_update_hardware_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :patch, + uri_template: "/v1alpha/{hardware.name}", + body: "hardware", + matches: [ + ["hardware.name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_hardware REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_hardware_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_comments REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_comments_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/comments", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_comment_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/comments/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_comment_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/comments", + body: "comment", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the record_action_on_comment REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_record_action_on_comment_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:recordAction", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/comments/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_change_log_entries REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_change_log_entries_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/changeLogEntries", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_change_log_entry REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_change_log_entry_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/changeLogEntries/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_skus REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_skus_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/skus", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_sku REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_sku_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/skus/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_zones REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_zones_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{parent}/zones", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_zone_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_zone_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{parent}/zones", + body: "zone", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the update_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_update_zone_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :patch, + uri_template: "/v1alpha/{zone.name}", + body: "zone", + matches: [ + ["zone.name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_zone REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_zone_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1alpha/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the signal_zone_state REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_signal_zone_state_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:signal", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the request_order_date_change REST call + # + # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_request_order_date_change_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1alpha/{name}:requestDateChange", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + end + end + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb new file mode 100644 index 000000000000..30ef342103a5 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb @@ -0,0 +1,38 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" +require "google/cloud/gdc_hardware_management/v1alpha/bindings_override" +require "google/cloud/gdc_hardware_management/v1alpha/version" + +module Google + module Cloud + module GDCHardwareManagement + ## + # To load just the REST part of this package, including all its services, and instantiate a REST client: + # + # @example + # + # require "google/cloud/gdc_hardware_management/v1alpha/rest" + # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new + # + module V1alpha + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb new file mode 100644 index 000000000000..b560b3e7f8df --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb @@ -0,0 +1,28 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + VERSION = "0.0.1" + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb new file mode 100644 index 000000000000..ace5f72be29f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb @@ -0,0 +1,99 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/gdchardwaremanagement/v1alpha/resources.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/field_info_pb' +require 'google/api/resource_pb' +require 'google/protobuf/timestamp_pb' +require 'google/type/date_pb' +require 'google/type/datetime_pb' +require 'google/type/dayofweek_pb' +require 'google/type/postal_address_pb' +require 'google/type/timeofday_pb' + + +descriptor_data = "\n:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\x1a\x1agoogle/type/datetime.proto\x1a\x1bgoogle/type/dayofweek.proto\x1a google/type/postal_address.proto\x1a\x1bgoogle/type/timeofday.proto\"\xf6\x0f\n\x05Order\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\r \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12R\n\x06labels\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Order.LabelsEntryB\x03\xe0\x41\x01\x12K\n\x05state\x18\x05 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.Order.StateB\x03\xe0\x41\x03\x12\x62\n\x14organization_contact\x18\x06 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12\x1d\n\x10target_workloads\x18\x07 \x03(\tB\x03\xe0\x41\x01\x12 \n\x13\x63ustomer_motivation\x18\x08 \x01(\tB\x03\xe0\x41\x02\x12;\n\x10\x66ulfillment_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x05\x18\x01\xe0\x41\x01\x12\x44\n$customer_requested_installation_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x18\n\x0bregion_code\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x1b\n\x0eorder_form_uri\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12I\n\x04type\x18\x0c \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Order.TypeB\x03\xe0\x41\x03\x12\x34\n\x0bsubmit_time\x18\x0e \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x0f \x01(\tB\x03\xe0\x41\x03\x12\\\n\x11\x65xisting_hardware\x18\x10 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.HardwareLocationB\x03\xe0\x41\x01\x12^\n\x0f\x64\x65ployment_type\x18\x12 \x01(\x0e\x32@.google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentTypeB\x03\xe0\x41\x03\x12\x38\n\x18\x61\x63tual_installation_date\x18\x13 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12;\n\x1b\x65stimated_installation_date\x18\x14 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x16 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x16\n\tmigration\x18\x17 \x01(\x08\x42\x03\xe0\x41\x01\x12\x36\n\raccepted_time\x18\x18 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x35\n\x15requested_date_change\x18\x19 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x19\n\x0cvendor_notes\x18\x1a \x01(\tB\x03\xe0\x41\x03\x12\\\n\x0evendor_contact\x18\x1b \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xe4\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\t\n\x05\x44RAFT\x10\x01\x12\r\n\tSUBMITTED\x10\x02\x12\x11\n\rINFO_COMPLETE\x10\x0c\x12\x0c\n\x08\x41\x43\x43\x45PTED\x10\x03\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x04\x12\x0c\n\x08\x42UILDING\x10\x05\x12\x0c\n\x08SHIPPING\x10\x06\x12\x0e\n\nINSTALLING\x10\x07\x12\n\n\x06\x46\x41ILED\x10\x08\x12\x17\n\x13PARTIALLY_COMPLETED\x10\t\x12\r\n\tCOMPLETED\x10\n\x12\r\n\tCANCELLED\x10\x0b\"?\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04PAID\x10\x01\x12\x07\n\x03POC\x10\x02\x12\n\n\x06UNPAID\x10\x02\x1a\x02\x10\x01\"|\n\x0e\x44\x65ploymentType\x12\x1f\n\x1b\x44\x45PLOYMENT_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x46ULL_PRODUCTION\x10\x01\x12\x14\n\x10PROOF_OF_CONCEPT\x10\x02\x12\x0c\n\x08INTERNAL\x10\x03\x12\x10\n\x0c\x43USTOMER_LAB\x10\x04:v\xea\x41s\n*gdchardwaremanagement.googleapis.com/Order\x12\x36projects/{project}/locations/{location}/orders/{order}*\x06orders2\x05order\"\xbb\x05\n\x04Site\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x18 \x01(\tB\x03\xe0\x41\x01\x12\x18\n\x0b\x64\x65scription\x18\x19 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Site.LabelsEntryB\x03\xe0\x41\x01\x12\x62\n\x14organization_contact\x18\x05 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12 \n\x13google_maps_pin_uri\x18\x06 \x01(\tB\x03\xe0\x41\x01\x12Q\n\x0c\x61\x63\x63\x65ss_times\x18\x1a \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\x12\x12\n\x05notes\x18\x1b \x01(\tB\x03\xe0\x41\x01\x12\x1d\n\x10\x63ustomer_site_id\x18\x1c \x01(\tB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Site\x12\x34projects/{project}/locations/{location}/sites/{site}*\x05sites2\x04site\"\xec\x07\n\rHardwareGroup\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Z\n\x06labels\x18\x04 \x03(\x0b\x32\x45.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.LabelsEntryB\x03\xe0\x41\x01\x12\x1b\n\x0ehardware_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02\x12O\n\x06\x63onfig\x18\x06 \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12?\n\x04site\x18\x07 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12S\n\x05state\x18\x08 \x01(\x0e\x32?.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.StateB\x03\xe0\x41\x03\x12?\n\x04zone\x18\t \x01(\tB1\xe0\x41\x01\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12=\n\x1brequested_installation_date\x18\n \x01(\x0b\x32\x11.google.type.DateB\x05\x18\x01\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x9a\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\x17\n\x13PARTIALLY_INSTALLED\x10\x05\x12\r\n\tINSTALLED\x10\x06\x12\n\n\x06\x46\x41ILED\x10\x07:\xaf\x01\xea\x41\xab\x01\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12Vprojects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}*\x0ehardwareGroups2\rhardwareGroup\"\x99\x11\n\x08Hardware\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12U\n\x06labels\x18\x05 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.LabelsEntryB\x03\xe0\x41\x01\x12\x41\n\x05order\x18\x06 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12R\n\x0ehardware_group\x18\x07 \x01(\tB:\xe0\x41\x03\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12?\n\x04site\x18\x08 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12N\n\x05state\x18\t \x01(\x0e\x32:.google.cloud.gdchardwaremanagement.v1alpha.Hardware.StateB\x03\xe0\x41\x03\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12O\n\x06\x63onfig\x18\x0b \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12;\n\x1b\x65stimated_installation_date\x18\x0c \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rphysical_info\x18\r \x01(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfoB\x03\xe0\x41\x01\x12\x64\n\x11installation_info\x18\x0e \x01(\x0b\x32\x44.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfoB\x03\xe0\x41\x01\x12?\n\x04zone\x18\x0f \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12;\n\x1brequested_installation_date\x18\x10 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x38\n\x18\x61\x63tual_installation_date\x18\x11 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rmachine_infos\x18\x14 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfoB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x1a\xf1\x01\n\nMacAddress\x12\x14\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12^\n\x04type\x18\x02 \x01(\x0e\x32K.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressTypeB\x03\xe0\x41\x03\x12!\n\x0cipv4_address\x18\x03 \x01(\tB\x0b\xe0\x41\x03\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"J\n\x0b\x41\x64\x64ressType\x12\x1c\n\x18\x41\x44\x44RESS_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03NIC\x10\x01\x12\x07\n\x03\x42MC\x10\x02\x12\x0b\n\x07VIRTUAL\x10\x03\x1a\x9c\x01\n\x08\x44iskInfo\x12\x19\n\x0cmanufacturer\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04slot\x18\x02 \x01(\x05\x42\x03\xe0\x41\x03\x12\x1a\n\rserial_number\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04psid\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0bpart_number\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cmodel_number\x18\x06 \x01(\tB\x03\xe0\x41\x03\x1a\xef\x01\n\x0bMachineInfo\x12\x18\n\x0bservice_tag\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12[\n\rmac_addresses\x18\x02 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddressB\x03\xe0\x41\x03\x12\x11\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12V\n\ndisk_infos\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfoB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x81\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\r\n\tINSTALLED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06:\x84\x01\xea\x41\x80\x01\n-gdchardwaremanagement.googleapis.com/Hardware\x12;projects/{project}/locations/{location}/hardware/{hardware}*\x08hardware2\x08hardware\"\xa1\x04\n\x07\x43omment\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12T\n\x06labels\x18\x03 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Comment.LabelsEntryB\x03\xe0\x41\x01\x12\x13\n\x06\x61uthor\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04text\x18\x05 \x01(\tB\x03\xe0\x41\x02\x12=\n\x14\x63ustomer_viewed_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12N\n\rauthor_entity\x18\x07 \x01(\x0e\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.EntityB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\x90\x01\xea\x41\x8c\x01\n,gdchardwaremanagement.googleapis.com/Comment\x12Iprojects/{project}/locations/{location}/orders/{order}/comments/{comment}*\x08\x63omments2\x07\x63omment\"\xb1\x03\n\x0e\x43hangeLogEntry\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12[\n\x06labels\x18\x03 \x03(\x0b\x32\x46.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry.LabelsEntryB\x03\xe0\x41\x01\x12\x10\n\x03log\x18\x04 \x01(\tB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xb7\x01\xea\x41\xb3\x01\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12Zprojects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}*\x10\x63hangeLogEntries2\x0e\x63hangeLogEntry\"\x8a\x06\n\x03Sku\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12J\n\x06\x63onfig\x18\x06 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.SkuConfigB\x03\xe0\x41\x03\x12O\n\tinstances\x18\x07 \x03(\x0b\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.SkuInstanceB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x65scription\x18\x08 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0brevision_id\x18\t \x01(\tB\x03\xe0\x41\x03\x12\x16\n\tis_active\x18\n \x01(\x08\x42\x03\xe0\x41\x03\x12G\n\x04type\x18\x0b \x01(\x0e\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Sku.TypeB\x03\xe0\x41\x03\x12\x17\n\nvcpu_count\x18\x0c \x01(\x05\x42\x03\xe0\x41\x03\x12Y\n\x15hardware_count_ranges\x18\r \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.Sku.RangeB\x03\xe0\x41\x03\x1a!\n\x05Range\x12\x0b\n\x03min\x18\x01 \x01(\x05\x12\x0b\n\x03max\x18\x02 \x01(\x05\"2\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04RACK\x10\x01\x12\n\n\x06SERVER\x10\x02:l\xea\x41i\n(gdchardwaremanagement.googleapis.com/Sku\x12\x32projects/{project}/locations/{location}/skus/{sku}*\x04skus2\x03sku\"\x9e\x0b\n\x04Zone\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Zone.LabelsEntryB\x03\xe0\x41\x01\x12\x19\n\x0c\x64isplay_name\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12J\n\x05state\x18\x08 \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Zone.StateB\x03\xe0\x41\x03\x12J\n\x08\x63ontacts\x18\t \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12Z\n\x0enetwork_config\x18\x0b \x01(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfigB\x03\xe0\x41\x01\x12\x1f\n\x12globally_unique_id\x18\x0c \x01(\tB\x03\xe0\x41\x03\x12\x61\n\x14subscription_configs\x18\r \x03(\x0b\x32>.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfigB\x03\xe0\x41\x03\x12\x63\n\x12provisioning_state\x18\x0e \x01(\x0e\x32\x42.google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningStateB\x03\xe0\x41\x03\x12&\n\x19skip_cluster_provisioning\x18\x10 \x01(\x08\x42\x03\xe0\x41\x01\x12$\n\x17\x63luster_intent_required\x18\x11 \x01(\x08\x42\x03\xe0\x41\x03\x12$\n\x17\x63luster_intent_verified\x18\x12 \x01(\x08\x42\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x91\x02\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\r\n\tPREPARING\x10\x02\x12,\n(READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS\x10\x05\x12*\n&CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED\x10\x08\x12\x19\n\x15READY_FOR_SITE_TURNUP\x10\x06\x12\x0b\n\x07OFFLINE\x10\t\x12)\n%CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED\x10\x07\x12\n\n\x06\x41\x43TIVE\x10\x03\x12\r\n\tCANCELLED\x10\x04\"\x8b\x01\n\x11ProvisioningState\x12\"\n\x1ePROVISIONING_STATE_UNSPECIFIED\x10\x00\x12\x19\n\x15PROVISIONING_REQUIRED\x10\x01\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x02\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x03:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Zone\x12\x34projects/{project}/locations/{location}/zones/{zone}*\x05zones2\x04zone\"\xbb\x01\n\x13OrganizationContact\x12\x30\n\x07\x61\x64\x64ress\x18\x01 \x01(\x0b\x32\x1a.google.type.PostalAddressB\x03\xe0\x41\x02\x12\x12\n\x05\x65mail\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05phone\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12J\n\x08\x63ontacts\x18\x04 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\"\xe9\x01\n\x07\x43ontact\x12\x17\n\ngiven_name\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\x18\n\x0b\x66\x61mily_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x65mail\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x12\n\x05phone\x18\x04 \x01(\tB\x03\xe0\x41\x02\x12-\n\ttime_zone\x18\x05 \x01(\x0b\x32\x15.google.type.TimeZoneB\x03\xe0\x41\x01\x12T\n\x0freachable_times\x18\x06 \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\"\xce\x01\n\x0eHardwareConfig\x12=\n\x03sku\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\x12R\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupplyB\x03\xe0\x41\x02\x12)\n\x1csubscription_duration_months\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\"C\n\tSkuConfig\x12\x0b\n\x03\x63pu\x18\x01 \x01(\t\x12\x0b\n\x03gpu\x18\x02 \x01(\t\x12\x0b\n\x03ram\x18\x03 \x01(\t\x12\x0f\n\x07storage\x18\x04 \x01(\t\"\xca\x01\n\x0bSkuInstance\x12\x13\n\x0bregion_code\x18\x01 \x01(\t\x12M\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupply\x12\x13\n\x0b\x62illing_sku\x18\x03 \x01(\t\x12\x1c\n\x14\x62illing_sku_per_vcpu\x18\x04 \x01(\t\x12$\n\x1csubscription_duration_months\x18\x05 \x01(\x05\"\xa1\x06\n\x14HardwarePhysicalInfo\x12s\n\x10power_receptacle\x18\x01 \x01(\x0e\x32T.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleTypeB\x03\xe0\x41\x02\x12o\n\x0enetwork_uplink\x18\x02 \x01(\x0e\x32R.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkTypeB\x03\xe0\x41\x02\x12^\n\x07voltage\x18\x03 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.VoltageB\x03\xe0\x41\x02\x12^\n\x07\x61mperes\x18\x04 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.AmperesB\x03\xe0\x41\x02\"\xa3\x01\n\x13PowerReceptacleType\x12%\n!POWER_RECEPTACLE_TYPE_UNSPECIFIED\x10\x00\x12\r\n\tNEMA_5_15\x10\x01\x12\x08\n\x04\x43_13\x10\x02\x12\x13\n\x0bSTANDARD_EU\x10\x03\x1a\x02\x08\x01\x12\x11\n\rTYPE_G_BS1363\x10\x04\x12\x0b\n\x07\x43\x45\x45_7_3\x10\x05\x12\x0b\n\x07\x43\x45\x45_7_5\x10\x06\x12\n\n\x06TYPE_F\x10\x07\"C\n\x11NetworkUplinkType\x12#\n\x1fNETWORK_UPLINK_TYPE_UNSPECIFIED\x10\x00\x12\t\n\x05RJ_45\x10\x01\"D\n\x07Voltage\x12\x17\n\x13VOLTAGE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bVOLTAGE_110\x10\x01\x12\x0f\n\x0bVOLTAGE_220\x10\x03\"2\n\x07\x41mperes\x12\x17\n\x13\x41MPERES_UNSPECIFIED\x10\x00\x12\x0e\n\nAMPERES_15\x10\x01\"\xd5\x03\n\x18HardwareInstallationInfo\x12\x1a\n\rrack_location\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\"\n\x15power_distance_meters\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\x12#\n\x16switch_distance_meters\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02\x12Y\n\x14rack_unit_dimensions\x18\x04 \x01(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.DimensionsB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x05 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x02\x12\x65\n\track_type\x18\x06 \x01(\x0e\x32M.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackTypeB\x03\xe0\x41\x02\"B\n\x08RackType\x12\x19\n\x15RACK_TYPE_UNSPECIFIED\x10\x00\x12\x0c\n\x08TWO_POST\x10\x01\x12\r\n\tFOUR_POST\x10\x02\"\xb0\x03\n\x11ZoneNetworkConfig\x12,\n\x17machine_mgmt_ipv4_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1akubernetes_node_ipv4_range\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\x38\n#kubernetes_control_plane_ipv4_range\x18\x03 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12W\n\x16management_ipv4_subnet\x18\x04 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x02\x12W\n\x16kubernetes_ipv4_subnet\x18\x05 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x01\x12\'\n\x12\x64ns_ipv4_addresses\x18\x06 \x03(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\'\n\x1akubernetes_primary_vlan_id\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\"]\n\x06Subnet\x12\"\n\raddress_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1a\x64\x65\x66\x61ult_gateway_ip_address\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"\x97\x01\n\nTimePeriod\x12/\n\nstart_time\x18\x01 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12-\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12)\n\x04\x64\x61ys\x18\x03 \x03(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x02\"^\n\nDimensions\x12\x19\n\x0cwidth_inches\x18\x01 \x01(\x02\x42\x03\xe0\x41\x02\x12\x1a\n\rheight_inches\x18\x02 \x01(\x02\x42\x03\xe0\x41\x02\x12\x19\n\x0c\x64\x65pth_inches\x18\x03 \x01(\x02\x42\x03\xe0\x41\x02\"E\n\tRackSpace\x12\x1c\n\x0fstart_rack_unit\x18\x01 \x01(\x05\x42\x03\xe0\x41\x02\x12\x1a\n\rend_rack_unit\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\"\xbf\x01\n\x10HardwareLocation\x12?\n\x04site\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1a\n\rrack_location\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x03 \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x01\"\xb7\x02\n\x12SubscriptionConfig\x12\x1c\n\x0fsubscription_id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x64\n\x05state\x18\x03 \x01(\x0e\x32P.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionStateB\x03\xe0\x41\x03\"\x83\x01\n\x11SubscriptionState\x12\"\n\x1eSUBSCRIPTION_STATE_UNSPECIFIED\x10\x00\x12\n\n\x06\x41\x43TIVE\x10\x01\x12\x0c\n\x08INACTIVE\x10\x02\x12\t\n\x05\x45RROR\x10\x03\x12\x16\n\x12\x46\x41ILED_TO_RETRIEVE\x10\x04\x12\r\n\tCOMPLETED\x10\x05*U\n\x0bPowerSupply\x12\x1c\n\x18POWER_SUPPLY_UNSPECIFIED\x10\x00\x12\x13\n\x0fPOWER_SUPPLY_AC\x10\x01\x12\x13\n\x0fPOWER_SUPPLY_DC\x10\x02*F\n\x06\x45ntity\x12\x16\n\x12\x45NTITY_UNSPECIFIED\x10\x00\x12\n\n\x06GOOGLE\x10\x01\x12\x0c\n\x08\x43USTOMER\x10\x02\x12\n\n\x06VENDOR\x10\x03\x42\xb2\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0eResourcesProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.type.Date", "google/type/date.proto"], + ["google.type.PostalAddress", "google/type/postal_address.proto"], + ["google.type.TimeZone", "google/type/datetime.proto"], + ["google.type.TimeOfDay", "google/type/timeofday.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + Order = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order").msgclass + Order::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.State").enummodule + Order::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.Type").enummodule + Order::DeploymentType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentType").enummodule + Site = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Site").msgclass + HardwareGroup = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup").msgclass + HardwareGroup::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.State").enummodule + Hardware = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware").msgclass + Hardware::MacAddress = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress").msgclass + Hardware::MacAddress::AddressType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressType").enummodule + Hardware::DiskInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfo").msgclass + Hardware::MachineInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfo").msgclass + Hardware::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.State").enummodule + Comment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Comment").msgclass + ChangeLogEntry = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry").msgclass + Sku = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku").msgclass + Sku::Range = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku.Range").msgclass + Sku::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku.Type").enummodule + Zone = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone").msgclass + Zone::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone.State").enummodule + Zone::ProvisioningState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningState").enummodule + OrganizationContact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.OrganizationContact").msgclass + Contact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Contact").msgclass + HardwareConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareConfig").msgclass + SkuConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SkuConfig").msgclass + SkuInstance = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SkuInstance").msgclass + HardwarePhysicalInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo").msgclass + HardwarePhysicalInfo::PowerReceptacleType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleType").enummodule + HardwarePhysicalInfo::NetworkUplinkType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkType").enummodule + HardwarePhysicalInfo::Voltage = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.Voltage").enummodule + HardwarePhysicalInfo::Amperes = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.Amperes").enummodule + HardwareInstallationInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo").msgclass + HardwareInstallationInfo::RackType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackType").enummodule + ZoneNetworkConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfig").msgclass + Subnet = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Subnet").msgclass + TimePeriod = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.TimePeriod").msgclass + Dimensions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Dimensions").msgclass + RackSpace = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RackSpace").msgclass + HardwareLocation = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareLocation").msgclass + SubscriptionConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig").msgclass + SubscriptionConfig::SubscriptionState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionState").enummodule + PowerSupply = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.PowerSupply").enummodule + Entity = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Entity").enummodule + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb new file mode 100644 index 000000000000..644c021c1880 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb @@ -0,0 +1,107 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/gdchardwaremanagement/v1alpha/service.proto + +require 'google/protobuf' + +require 'google/api/annotations_pb' +require 'google/api/client_pb' +require 'google/api/field_behavior_pb' +require 'google/api/field_info_pb' +require 'google/api/resource_pb' +require 'google/cloud/gdchardwaremanagement/v1alpha/resources_pb' +require 'google/longrunning/operations_pb' +require 'google/protobuf/empty_pb' +require 'google/protobuf/field_mask_pb' +require 'google/protobuf/timestamp_pb' +require 'google/type/date_pb' + + +descriptor_data = "\n8google/cloud/gdchardwaremanagement/v1alpha/service.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x1a#google/longrunning/operations.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\"\xb4\x01\n\x11ListOrdersRequest\x12\x42\n\x06parent\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\x12*gdchardwaremanagement.googleapis.com/Order\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x85\x01\n\x12ListOrdersResponse\x12\x41\n\x06orders\x18\x01 \x03(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.Order\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"S\n\x0fGetOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\"\xcf\x01\n\x12\x43reateOrderRequest\x12\x42\n\x06parent\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\x12*gdchardwaremanagement.googleapis.com/Order\x12\x15\n\x08order_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x45\n\x05order\x18\x03 \x01(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.OrderB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xaa\x01\n\x12UpdateOrderRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x45\n\x05order\x18\x02 \x01(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.OrderB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x83\x01\n\x12\x44\x65leteOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x66orce\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\x8a\x02\n\x12SubmitOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12V\n\x04type\x18\x03 \x01(\x0e\x32\x43.google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest.TypeB\x03\xe0\x41\x01\"A\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x10\n\x0cINFO_PENDING\x10\x01\x12\x11\n\rINFO_COMPLETE\x10\x02\"w\n\x12\x43\x61ncelOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xb2\x01\n\x10ListSitesRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Site\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x82\x01\n\x11ListSitesResponse\x12?\n\x05sites\x18\x01 \x03(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.Site\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Q\n\x0eGetSiteRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\"\xca\x01\n\x11\x43reateSiteRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Site\x12\x14\n\x07site_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x43\n\x04site\x18\x03 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.SiteB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xa7\x01\n\x11UpdateSiteRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x43\n\x04site\x18\x02 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.SiteB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"u\n\x11\x44\x65leteSiteRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xc4\x01\n\x19ListHardwareGroupsRequest\x12J\n\x06parent\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\x12\x32gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x9e\x01\n\x1aListHardwareGroupsResponse\x12R\n\x0fhardware_groups\x18\x01 \x03(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"c\n\x17GetHardwareGroupRequest\x12H\n\x04name\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\"\xf9\x01\n\x1a\x43reateHardwareGroupRequest\x12J\n\x06parent\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\x12\x32gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x1e\n\x11hardware_group_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12V\n\x0ehardware_group\x18\x03 \x01(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroupB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xc3\x01\n\x1aUpdateHardwareGroupRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12V\n\x0ehardware_group\x18\x02 \x01(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroupB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x7f\n\x1a\x44\x65leteHardwareGroupRequest\x12H\n\x04name\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\"\xb9\x01\n\x13ListHardwareRequest\x12\x45\n\x06parent\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\x12-gdchardwaremanagement.googleapis.com/Hardware\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x8c\x01\n\x14ListHardwareResponse\x12\x46\n\x08hardware\x18\x01 \x03(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Hardware\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Y\n\x12GetHardwareRequest\x12\x43\n\x04name\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\n-gdchardwaremanagement.googleapis.com/Hardware\"\xc5\x01\n\x15\x43reateHardwareRequest\x12\x45\n\x06parent\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\x12-gdchardwaremanagement.googleapis.com/Hardware\x12\x18\n\x0bhardware_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12K\n\x08hardware\x18\x03 \x01(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.HardwareB\x03\xe0\x41\x02\"\xb3\x01\n\x15UpdateHardwareRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12K\n\x08hardware\x18\x02 \x01(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.HardwareB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"}\n\x15\x44\x65leteHardwareRequest\x12\x43\n\x04name\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\n-gdchardwaremanagement.googleapis.com/Hardware\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xb8\x01\n\x13ListCommentsRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,gdchardwaremanagement.googleapis.com/Comment\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x8b\x01\n\x14ListCommentsResponse\x12\x45\n\x08\x63omments\x18\x01 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"W\n\x11GetCommentRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,gdchardwaremanagement.googleapis.com/Comment\"\xd9\x01\n\x14\x43reateCommentRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,gdchardwaremanagement.googleapis.com/Comment\x12\x17\n\ncomment_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12I\n\x07\x63omment\x18\x03 \x01(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.CommentB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x92\x02\n\x1cRecordActionOnCommentRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,gdchardwaremanagement.googleapis.com/Comment\x12m\n\x0b\x61\x63tion_type\x18\x02 \x01(\x0e\x32S.google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest.ActionTypeB\x03\xe0\x41\x02\"?\n\nActionType\x12\x1b\n\x17\x41\x43TION_TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04READ\x10\x01\x12\n\n\x06UNREAD\x10\x02\"\xc7\x01\n\x1bListChangeLogEntriesRequest\x12K\n\x06parent\x18\x01 \x01(\tB;\xe0\x41\x02\xfa\x41\x35\x12\x33gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\xa4\x01\n\x1cListChangeLogEntriesResponse\x12V\n\x12\x63hange_log_entries\x18\x01 \x03(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"e\n\x18GetChangeLogEntryRequest\x12I\n\x04name\x18\x01 \x01(\tB;\xe0\x41\x02\xfa\x41\x35\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\"\xb0\x01\n\x0fListSkusRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\x12(gdchardwaremanagement.googleapis.com/Sku\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x7f\n\x10ListSkusResponse\x12=\n\x04skus\x18\x01 \x03(\x0b\x32/.google.cloud.gdchardwaremanagement.v1alpha.Sku\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"O\n\rGetSkuRequest\x12>\n\x04name\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\"\xb2\x01\n\x10ListZonesRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Zone\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x82\x01\n\x11ListZonesResponse\x12?\n\x05zones\x18\x01 \x03(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.Zone\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Q\n\x0eGetZoneRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\"\xd2\x01\n\x11\x43reateZoneRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Zone\x12\x14\n\x07zone_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x43\n\x04zone\x18\x03 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.ZoneB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x04 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xaf\x01\n\x11UpdateZoneRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x43\n\x04zone\x18\x02 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.ZoneB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x03 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"u\n\x11\x44\x65leteZoneRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xee\x05\n\x16SignalZoneStateRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\x12i\n\x0cstate_signal\x18\x03 \x01(\x0e\x32N.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.StateSignalB\x03\xe0\x41\x01\x12\x82\x01\n\x19provisioning_state_signal\x18\x04 \x01(\x0e\x32Z.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.ProvisioningStateSignalB\x03\xe0\x41\x01\x12\x11\n\x04step\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12\x14\n\x07\x64\x65tails\x18\x06 \x01(\tB\x03\xe0\x41\x01\"\xd9\x01\n\x0bStateSignal\x12\x1c\n\x18STATE_SIGNAL_UNSPECIFIED\x10\x00\x12!\n\x1d\x46\x41\x43TORY_TURNUP_CHECKS_STARTED\x10\x03\x12 \n\x1c\x46\x41\x43TORY_TURNUP_CHECKS_PASSED\x10\x01\x12\x1d\n\x15READY_FOR_SITE_TURNUP\x10\x01\x1a\x02\x08\x01\x12 \n\x1c\x46\x41\x43TORY_TURNUP_CHECKS_FAILED\x10\x02\x12\"\n\x1eVERIFY_CLUSTER_INTENT_PRESENCE\x10\x04\x1a\x02\x10\x01\"}\n\x17ProvisioningStateSignal\x12)\n%PROVISIONING_STATE_SIGNAL_UNSPECIFIED\x10\x00\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x01\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x02\"\x80\x02\n\x11OperationMetadata\x12\x34\n\x0b\x63reate_time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x31\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x13\n\x06target\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04verb\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x1b\n\x0estatus_message\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12#\n\x16requested_cancellation\x18\x06 \x01(\x08\x42\x03\xe0\x41\x03\x12\x18\n\x0b\x61pi_version\x18\x07 \x01(\tB\x03\xe0\x41\x03\"\x91\x01\n\x1dRequestOrderDateChangeRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12.\n\x0erequested_date\x18\x02 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x02\x32\xaf\x42\n\x15GDCHardwareManagement\x12\xcd\x01\n\nListOrders\x12=.google.cloud.gdchardwaremanagement.v1alpha.ListOrdersRequest\x1a>.google.cloud.gdchardwaremanagement.v1alpha.ListOrdersResponse\"@\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x31\x12//v1alpha/{parent=projects/*/locations/*}/orders\x12\xba\x01\n\x08GetOrder\x12;.google.cloud.gdchardwaremanagement.v1alpha.GetOrderRequest\x1a\x31.google.cloud.gdchardwaremanagement.v1alpha.Order\">\xda\x41\x04name\x82\xd3\xe4\x93\x02\x31\x12//v1alpha/{name=projects/*/locations/*/orders/*}\x12\xe1\x01\n\x0b\x43reateOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.CreateOrderRequest\x1a\x1d.google.longrunning.Operation\"s\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x15parent,order,order_id\x82\xd3\xe4\x93\x02\x38\"//v1alpha/{parent=projects/*/locations/*}/orders:\x05order\x12\xe3\x01\n\x0bUpdateOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.UpdateOrderRequest\x1a\x1d.google.longrunning.Operation\"u\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x11order,update_mask\x82\xd3\xe4\x93\x02>25/v1alpha/{order.name=projects/*/locations/*/orders/*}:\x05order\x12\xd9\x01\n\x0b\x44\x65leteOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.DeleteOrderRequest\x1a\x1d.google.longrunning.Operation\"k\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x31*//v1alpha/{name=projects/*/locations/*/orders/*}\x12\xd3\x01\n\x0bSubmitOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest\x1a\x1d.google.longrunning.Operation\"e\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02;\"6/v1alpha/{name=projects/*/locations/*/orders/*}:submit:\x01*\x12\xd3\x01\n\x0b\x43\x61ncelOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.CancelOrderRequest\x1a\x1d.google.longrunning.Operation\"e\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02;\"6/v1alpha/{name=projects/*/locations/*/orders/*}:cancel:\x01*\x12\xc9\x01\n\tListSites\x12<.google.cloud.gdchardwaremanagement.v1alpha.ListSitesRequest\x1a=.google.cloud.gdchardwaremanagement.v1alpha.ListSitesResponse\"?\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{parent=projects/*/locations/*}/sites\x12\xb6\x01\n\x07GetSite\x12:.google.cloud.gdchardwaremanagement.v1alpha.GetSiteRequest\x1a\x30.google.cloud.gdchardwaremanagement.v1alpha.Site\"=\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{name=projects/*/locations/*/sites/*}\x12\xda\x01\n\nCreateSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.CreateSiteRequest\x1a\x1d.google.longrunning.Operation\"n\xca\x41\x19\n\x04Site\x12\x11OperationMetadata\xda\x41\x13parent,site,site_id\x82\xd3\xe4\x93\x02\x36\"./v1alpha/{parent=projects/*/locations/*}/sites:\x04site\x12\xdc\x01\n\nUpdateSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.UpdateSiteRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Site\x12\x11OperationMetadata\xda\x41\x10site,update_mask\x82\xd3\xe4\x93\x02;23/v1alpha/{site.name=projects/*/locations/*/sites/*}:\x04site\x12\xd6\x01\n\nDeleteSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.DeleteSiteRequest\x1a\x1d.google.longrunning.Operation\"j\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30*./v1alpha/{name=projects/*/locations/*/sites/*}\x12\xf6\x01\n\x12ListHardwareGroups\x12\x45.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsRequest\x1a\x46.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsResponse\"Q\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x42\x12@/v1alpha/{parent=projects/*/locations/*/orders/*}/hardwareGroups\x12\xe3\x01\n\x10GetHardwareGroup\x12\x43.google.cloud.gdchardwaremanagement.v1alpha.GetHardwareGroupRequest\x1a\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup\"O\xda\x41\x04name\x82\xd3\xe4\x93\x02\x42\x12@/v1alpha/{name=projects/*/locations/*/orders/*/hardwareGroups/*}\x12\xa6\x02\n\x13\x43reateHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"\xa7\x01\xca\x41\"\n\rHardwareGroup\x12\x11OperationMetadata\xda\x41\'parent,hardware_group,hardware_group_id\x82\xd3\xe4\x93\x02R\"@/v1alpha/{parent=projects/*/locations/*/orders/*}/hardwareGroups:\x0ehardware_group\x12\xa8\x02\n\x13UpdateHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"\xa9\x01\xca\x41\"\n\rHardwareGroup\x12\x11OperationMetadata\xda\x41\x1ahardware_group,update_mask\x82\xd3\xe4\x93\x02\x61\x32O/v1alpha/{hardware_group.name=projects/*/locations/*/orders/*/hardwareGroups/*}:\x0ehardware_group\x12\xfa\x01\n\x13\x44\x65leteHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"|\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x42*@/v1alpha/{name=projects/*/locations/*/orders/*/hardwareGroups/*}\x12\xd5\x01\n\x0cListHardware\x12?.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareRequest\x1a@.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareResponse\"B\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x33\x12\x31/v1alpha/{parent=projects/*/locations/*}/hardware\x12\xc5\x01\n\x0bGetHardware\x12>.google.cloud.gdchardwaremanagement.v1alpha.GetHardwareRequest\x1a\x34.google.cloud.gdchardwaremanagement.v1alpha.Hardware\"@\xda\x41\x04name\x82\xd3\xe4\x93\x02\x33\x12\x31/v1alpha/{name=projects/*/locations/*/hardware/*}\x12\xf6\x01\n\x0e\x43reateHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareRequest\x1a\x1d.google.longrunning.Operation\"\x81\x01\xca\x41\x1d\n\x08Hardware\x12\x11OperationMetadata\xda\x41\x1bparent,hardware,hardware_id\x82\xd3\xe4\x93\x02=\"1/v1alpha/{parent=projects/*/locations/*}/hardware:\x08hardware\x12\xf8\x01\n\x0eUpdateHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareRequest\x1a\x1d.google.longrunning.Operation\"\x83\x01\xca\x41\x1d\n\x08Hardware\x12\x11OperationMetadata\xda\x41\x14hardware,update_mask\x82\xd3\xe4\x93\x02\x46\x32:/v1alpha/{hardware.name=projects/*/locations/*/hardware/*}:\x08hardware\x12\xe1\x01\n\x0e\x44\x65leteHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareRequest\x1a\x1d.google.longrunning.Operation\"m\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x33*1/v1alpha/{name=projects/*/locations/*/hardware/*}\x12\xde\x01\n\x0cListComments\x12?.google.cloud.gdchardwaremanagement.v1alpha.ListCommentsRequest\x1a@.google.cloud.gdchardwaremanagement.v1alpha.ListCommentsResponse\"K\xda\x41\x06parent\x82\xd3\xe4\x93\x02<\x12:/v1alpha/{parent=projects/*/locations/*/orders/*}/comments\x12\xcb\x01\n\nGetComment\x12=.google.cloud.gdchardwaremanagement.v1alpha.GetCommentRequest\x1a\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\"I\xda\x41\x04name\x82\xd3\xe4\x93\x02<\x12:/v1alpha/{name=projects/*/locations/*/orders/*/comments/*}\x12\xf9\x01\n\rCreateComment\x12@.google.cloud.gdchardwaremanagement.v1alpha.CreateCommentRequest\x1a\x1d.google.longrunning.Operation\"\x86\x01\xca\x41\x1c\n\x07\x43omment\x12\x11OperationMetadata\xda\x41\x19parent,comment,comment_id\x82\xd3\xe4\x93\x02\x45\":/v1alpha/{parent=projects/*/locations/*/orders/*}/comments:\x07\x63omment\x12\xfd\x01\n\x15RecordActionOnComment\x12H.google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest\x1a\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\"e\xda\x41\x10name,action_type\x82\xd3\xe4\x93\x02L\"G/v1alpha/{name=projects/*/locations/*/orders/*/comments/*}:recordAction:\x01*\x12\xfe\x01\n\x14ListChangeLogEntries\x12G.google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesRequest\x1aH.google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesResponse\"S\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x44\x12\x42/v1alpha/{parent=projects/*/locations/*/orders/*}/changeLogEntries\x12\xe8\x01\n\x11GetChangeLogEntry\x12\x44.google.cloud.gdchardwaremanagement.v1alpha.GetChangeLogEntryRequest\x1a:.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry\"Q\xda\x41\x04name\x82\xd3\xe4\x93\x02\x44\x12\x42/v1alpha/{name=projects/*/locations/*/orders/*/changeLogEntries/*}\x12\xc5\x01\n\x08ListSkus\x12;.google.cloud.gdchardwaremanagement.v1alpha.ListSkusRequest\x1a<.google.cloud.gdchardwaremanagement.v1alpha.ListSkusResponse\">\xda\x41\x06parent\x82\xd3\xe4\x93\x02/\x12-/v1alpha/{parent=projects/*/locations/*}/skus\x12\xb2\x01\n\x06GetSku\x12\x39.google.cloud.gdchardwaremanagement.v1alpha.GetSkuRequest\x1a/.google.cloud.gdchardwaremanagement.v1alpha.Sku\"<\xda\x41\x04name\x82\xd3\xe4\x93\x02/\x12-/v1alpha/{name=projects/*/locations/*/skus/*}\x12\xc9\x01\n\tListZones\x12<.google.cloud.gdchardwaremanagement.v1alpha.ListZonesRequest\x1a=.google.cloud.gdchardwaremanagement.v1alpha.ListZonesResponse\"?\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{parent=projects/*/locations/*}/zones\x12\xb6\x01\n\x07GetZone\x12:.google.cloud.gdchardwaremanagement.v1alpha.GetZoneRequest\x1a\x30.google.cloud.gdchardwaremanagement.v1alpha.Zone\"=\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{name=projects/*/locations/*/zones/*}\x12\xda\x01\n\nCreateZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.CreateZoneRequest\x1a\x1d.google.longrunning.Operation\"n\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x13parent,zone,zone_id\x82\xd3\xe4\x93\x02\x36\"./v1alpha/{parent=projects/*/locations/*}/zones:\x04zone\x12\xdc\x01\n\nUpdateZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.UpdateZoneRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x10zone,update_mask\x82\xd3\xe4\x93\x02;23/v1alpha/{zone.name=projects/*/locations/*/zones/*}:\x04zone\x12\xd6\x01\n\nDeleteZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.DeleteZoneRequest\x1a\x1d.google.longrunning.Operation\"j\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30*./v1alpha/{name=projects/*/locations/*/zones/*}\x12\xe6\x01\n\x0fSignalZoneState\x12\x42.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x11name,state_signal\x82\xd3\xe4\x93\x02:\"5/v1alpha/{name=projects/*/locations/*/zones/*}:signal:\x01*\x12\x83\x02\n\x16RequestOrderDateChange\x12I.google.cloud.gdchardwaremanagement.v1alpha.RequestOrderDateChangeRequest\x1a\x1d.google.longrunning.Operation\"\x7f\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x13name,requested_date\x82\xd3\xe4\x93\x02\x46\"A/v1alpha/{name=projects/*/locations/*/orders/*}:requestDateChange:\x01*\x1aX\xca\x41$gdchardwaremanagement.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\xb0\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0cServiceProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.cloud.gdchardwaremanagement.v1alpha.Order", "google/cloud/gdchardwaremanagement/v1alpha/resources.proto"], + ["google.protobuf.FieldMask", "google/protobuf/field_mask.proto"], + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.type.Date", "google/type/date.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + ListOrdersRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListOrdersRequest").msgclass + ListOrdersResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListOrdersResponse").msgclass + GetOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetOrderRequest").msgclass + CreateOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateOrderRequest").msgclass + UpdateOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateOrderRequest").msgclass + DeleteOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteOrderRequest").msgclass + SubmitOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest").msgclass + SubmitOrderRequest::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest.Type").enummodule + CancelOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CancelOrderRequest").msgclass + ListSitesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSitesRequest").msgclass + ListSitesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSitesResponse").msgclass + GetSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetSiteRequest").msgclass + CreateSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateSiteRequest").msgclass + UpdateSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateSiteRequest").msgclass + DeleteSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteSiteRequest").msgclass + ListHardwareGroupsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsRequest").msgclass + ListHardwareGroupsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsResponse").msgclass + GetHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetHardwareGroupRequest").msgclass + CreateHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareGroupRequest").msgclass + UpdateHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareGroupRequest").msgclass + DeleteHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareGroupRequest").msgclass + ListHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareRequest").msgclass + ListHardwareResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareResponse").msgclass + GetHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetHardwareRequest").msgclass + CreateHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareRequest").msgclass + UpdateHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareRequest").msgclass + DeleteHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareRequest").msgclass + ListCommentsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListCommentsRequest").msgclass + ListCommentsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListCommentsResponse").msgclass + GetCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetCommentRequest").msgclass + CreateCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateCommentRequest").msgclass + RecordActionOnCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest").msgclass + RecordActionOnCommentRequest::ActionType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest.ActionType").enummodule + ListChangeLogEntriesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesRequest").msgclass + ListChangeLogEntriesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesResponse").msgclass + GetChangeLogEntryRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetChangeLogEntryRequest").msgclass + ListSkusRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSkusRequest").msgclass + ListSkusResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSkusResponse").msgclass + GetSkuRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetSkuRequest").msgclass + ListZonesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListZonesRequest").msgclass + ListZonesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListZonesResponse").msgclass + GetZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetZoneRequest").msgclass + CreateZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateZoneRequest").msgclass + UpdateZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateZoneRequest").msgclass + DeleteZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteZoneRequest").msgclass + SignalZoneStateRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest").msgclass + SignalZoneStateRequest::StateSignal = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.StateSignal").enummodule + SignalZoneStateRequest::ProvisioningStateSignal = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.ProvisioningStateSignal").enummodule + OperationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.OperationMetadata").msgclass + RequestOrderDateChangeRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RequestOrderDateChangeRequest").msgclass + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb new file mode 100644 index 000000000000..b7d920dba588 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb @@ -0,0 +1,120 @@ +# Generated by the protocol buffer compiler. DO NOT EDIT! +# Source: google/cloud/gdchardwaremanagement/v1alpha/service.proto for package 'Google.Cloud.GDCHardwareManagement.V1alpha' +# Original file comments: +# Copyright 2025 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +require 'grpc' +require 'google/cloud/gdchardwaremanagement/v1alpha/service_pb' + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + module GDCHardwareManagement + # The GDC Hardware Management service. + class Service + + include ::GRPC::GenericService + + self.marshal_class_method = :encode + self.unmarshal_class_method = :decode + self.service_name = 'google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement' + + # Lists orders in a given project and location. + rpc :ListOrders, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse + # Gets details of an order. + rpc :GetOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Order + # Creates a new order in a given project and location. + rpc :CreateOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Google::Longrunning::Operation + # Updates the parameters of an order. + rpc :UpdateOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Google::Longrunning::Operation + # Deletes an order. + rpc :DeleteOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Google::Longrunning::Operation + # Submits an order. + rpc :SubmitOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Google::Longrunning::Operation + # Cancels an order. + rpc :CancelOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Google::Longrunning::Operation + # Lists sites in a given project and location. + rpc :ListSites, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse + # Gets details of a site. + rpc :GetSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Site + # Creates a new site in a given project and location. + rpc :CreateSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Google::Longrunning::Operation + # Updates the parameters of a site. + rpc :UpdateSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Google::Longrunning::Operation + # Deletes a site. + rpc :DeleteSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Google::Longrunning::Operation + # Lists hardware groups in a given order. + rpc :ListHardwareGroups, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse + # Gets details of a hardware group. + rpc :GetHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup + # Creates a new hardware group in a given order. + rpc :CreateHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Google::Longrunning::Operation + # Updates the parameters of a hardware group. + rpc :UpdateHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Google::Longrunning::Operation + # Deletes a hardware group. + rpc :DeleteHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Google::Longrunning::Operation + # Lists hardware in a given project and location. + rpc :ListHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse + # Gets hardware details. + rpc :GetHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware + # Creates new hardware in a given project and location. + rpc :CreateHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Google::Longrunning::Operation + # Updates hardware parameters. + rpc :UpdateHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Google::Longrunning::Operation + # Deletes hardware. + rpc :DeleteHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Google::Longrunning::Operation + # Lists the comments on an order. + rpc :ListComments, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse + # Gets the content of a comment. + rpc :GetComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment + # Creates a new comment on an order. + rpc :CreateComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Google::Longrunning::Operation + # Record Action on a Comment. If the Action specified in the request is READ, + # the viewed time in the comment is set to the time the request was received. + # If the comment is already marked as read, subsequent calls will be ignored. + # If the Action is UNREAD, the viewed time is cleared from the comment. + rpc :RecordActionOnComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment + # Lists the changes made to an order. + rpc :ListChangeLogEntries, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse + # Gets details of a change to an order. + rpc :GetChangeLogEntry, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry + # Lists SKUs for a given project and location. + rpc :ListSkus, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse + # Gets details of an SKU. + rpc :GetSku, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku + # Lists zones in a given project and location. + rpc :ListZones, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse + # Gets details of a zone. + rpc :GetZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone + # Creates a new zone in a given project and location. + rpc :CreateZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Google::Longrunning::Operation + # Updates the parameters of a zone. + rpc :UpdateZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Google::Longrunning::Operation + # Deletes a zone. + rpc :DeleteZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Google::Longrunning::Operation + # Signals the state of a zone. + rpc :SignalZoneState, ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Google::Longrunning::Operation + # Updates the requested date change of a single Order. + rpc :RequestOrderDateChange, ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Google::Longrunning::Operation + end + + Stub = Service.rpc_stub_class + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md new file mode 100644 index 000000000000..7e80aeaac20b --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md @@ -0,0 +1,4 @@ +# GDC Hardware Management V1ALPHA Protocol Buffer Documentation + +These files are for the YARD documentation of the generated protobuf files. +They are not intended to be required or loaded at runtime. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb new file mode 100644 index 000000000000..d59ba51a5612 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb @@ -0,0 +1,473 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # Required information for every language. + # @!attribute [rw] reference_docs_uri + # @deprecated This field is deprecated and may be removed in the next major version update. + # @return [::String] + # Link to automatically generated reference documentation. Example: + # https://cloud.google.com/nodejs/docs/reference/asset/latest + # @!attribute [rw] destinations + # @return [::Array<::Google::Api::ClientLibraryDestination>] + # The destination where API teams want this client library to be published. + # @!attribute [rw] selective_gapic_generation + # @return [::Google::Api::SelectiveGapicGeneration] + # Configuration for which RPCs should be generated in the GAPIC client. + class CommonLanguageSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Details about how and where to publish client libraries. + # @!attribute [rw] version + # @return [::String] + # Version of the API to apply these settings to. This is the full protobuf + # package for the API, ending in the version element. + # Examples: "google.cloud.speech.v1" and "google.spanner.admin.database.v1". + # @!attribute [rw] launch_stage + # @return [::Google::Api::LaunchStage] + # Launch stage of this version of the API. + # @!attribute [rw] rest_numeric_enums + # @return [::Boolean] + # When using transport=rest, the client request will encode enums as + # numbers rather than strings. + # @!attribute [rw] java_settings + # @return [::Google::Api::JavaSettings] + # Settings for legacy Java features, supported in the Service YAML. + # @!attribute [rw] cpp_settings + # @return [::Google::Api::CppSettings] + # Settings for C++ client libraries. + # @!attribute [rw] php_settings + # @return [::Google::Api::PhpSettings] + # Settings for PHP client libraries. + # @!attribute [rw] python_settings + # @return [::Google::Api::PythonSettings] + # Settings for Python client libraries. + # @!attribute [rw] node_settings + # @return [::Google::Api::NodeSettings] + # Settings for Node client libraries. + # @!attribute [rw] dotnet_settings + # @return [::Google::Api::DotnetSettings] + # Settings for .NET client libraries. + # @!attribute [rw] ruby_settings + # @return [::Google::Api::RubySettings] + # Settings for Ruby client libraries. + # @!attribute [rw] go_settings + # @return [::Google::Api::GoSettings] + # Settings for Go client libraries. + class ClientLibrarySettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # This message configures the settings for publishing [Google Cloud Client + # libraries](https://cloud.google.com/apis/docs/cloud-client-libraries) + # generated from the service config. + # @!attribute [rw] method_settings + # @return [::Array<::Google::Api::MethodSettings>] + # A list of API method settings, e.g. the behavior for methods that use the + # long-running operation pattern. + # @!attribute [rw] new_issue_uri + # @return [::String] + # Link to a *public* URI where users can report issues. Example: + # https://issuetracker.google.com/issues/new?component=190865&template=1161103 + # @!attribute [rw] documentation_uri + # @return [::String] + # Link to product home page. Example: + # https://cloud.google.com/asset-inventory/docs/overview + # @!attribute [rw] api_short_name + # @return [::String] + # Used as a tracking tag when collecting data about the APIs developer + # relations artifacts like docs, packages delivered to package managers, + # etc. Example: "speech". + # @!attribute [rw] github_label + # @return [::String] + # GitHub label to apply to issues and pull requests opened for this API. + # @!attribute [rw] codeowner_github_teams + # @return [::Array<::String>] + # GitHub teams to be added to CODEOWNERS in the directory in GitHub + # containing source code for the client libraries for this API. + # @!attribute [rw] doc_tag_prefix + # @return [::String] + # A prefix used in sample code when demarking regions to be included in + # documentation. + # @!attribute [rw] organization + # @return [::Google::Api::ClientLibraryOrganization] + # For whom the client library is being published. + # @!attribute [rw] library_settings + # @return [::Array<::Google::Api::ClientLibrarySettings>] + # Client library settings. If the same version string appears multiple + # times in this list, then the last one wins. Settings from earlier + # settings with the same version string are discarded. + # @!attribute [rw] proto_reference_documentation_uri + # @return [::String] + # Optional link to proto reference documentation. Example: + # https://cloud.google.com/pubsub/lite/docs/reference/rpc + # @!attribute [rw] rest_reference_documentation_uri + # @return [::String] + # Optional link to REST reference documentation. Example: + # https://cloud.google.com/pubsub/lite/docs/reference/rest + class Publishing + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Java client libraries. + # @!attribute [rw] library_package + # @return [::String] + # The package name to use in Java. Clobbers the java_package option + # set in the protobuf. This should be used **only** by APIs + # who have already set the language_settings.java.package_name" field + # in gapic.yaml. API teams should use the protobuf java_package option + # where possible. + # + # Example of a YAML configuration:: + # + # publishing: + # java_settings: + # library_package: com.google.cloud.pubsub.v1 + # @!attribute [rw] service_class_names + # @return [::Google::Protobuf::Map{::String => ::String}] + # Configure the Java class name to use instead of the service's for its + # corresponding generated GAPIC client. Keys are fully-qualified + # service names as they appear in the protobuf (including the full + # the language_settings.java.interface_names" field in gapic.yaml. API + # teams should otherwise use the service name as it appears in the + # protobuf. + # + # Example of a YAML configuration:: + # + # publishing: + # java_settings: + # service_class_names: + # - google.pubsub.v1.Publisher: TopicAdmin + # - google.pubsub.v1.Subscriber: SubscriptionAdmin + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class JavaSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class ServiceClassNamesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for C++ client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class CppSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Php client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class PhpSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Python client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + # @!attribute [rw] experimental_features + # @return [::Google::Api::PythonSettings::ExperimentalFeatures] + # Experimental features to be included during client library generation. + class PythonSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Experimental features to be included during client library generation. + # These fields will be deprecated once the feature graduates and is enabled + # by default. + # @!attribute [rw] rest_async_io_enabled + # @return [::Boolean] + # Enables generation of asynchronous REST clients if `rest` transport is + # enabled. By default, asynchronous REST clients will not be generated. + # This feature will be enabled by default 1 month after launching the + # feature in preview packages. + # @!attribute [rw] protobuf_pythonic_types_enabled + # @return [::Boolean] + # Enables generation of protobuf code using new types that are more + # Pythonic which are included in `protobuf>=5.29.x`. This feature will be + # enabled by default 1 month after launching the feature in preview + # packages. + # @!attribute [rw] unversioned_package_disabled + # @return [::Boolean] + # Disables generation of an unversioned Python package for this client + # library. This means that the module names will need to be versioned in + # import statements. For example `import google.cloud.library_v2` instead + # of `import google.cloud.library`. + class ExperimentalFeatures + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for Node client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class NodeSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Dotnet client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + # @!attribute [rw] renamed_services + # @return [::Google::Protobuf::Map{::String => ::String}] + # Map from original service names to renamed versions. + # This is used when the default generated types + # would cause a naming conflict. (Neither name is + # fully-qualified.) + # Example: Subscriber to SubscriberServiceApi. + # @!attribute [rw] renamed_resources + # @return [::Google::Protobuf::Map{::String => ::String}] + # Map from full resource types to the effective short name + # for the resource. This is used when otherwise resource + # named from different services would cause naming collisions. + # Example entry: + # "datalabeling.googleapis.com/Dataset": "DataLabelingDataset" + # @!attribute [rw] ignored_resources + # @return [::Array<::String>] + # List of full resource types to ignore during generation. + # This is typically used for API-specific Location resources, + # which should be handled by the generator as if they were actually + # the common Location resources. + # Example entry: "documentai.googleapis.com/Location" + # @!attribute [rw] forced_namespace_aliases + # @return [::Array<::String>] + # Namespaces which must be aliased in snippets due to + # a known (but non-generator-predictable) naming collision + # @!attribute [rw] handwritten_signatures + # @return [::Array<::String>] + # Method signatures (in the form "service.method(signature)") + # which are provided separately, so shouldn't be generated. + # Snippets *calling* these methods are still generated, however. + class DotnetSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class RenamedServicesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class RenamedResourcesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for Ruby client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class RubySettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Go client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + # @!attribute [rw] renamed_services + # @return [::Google::Protobuf::Map{::String => ::String}] + # Map of service names to renamed services. Keys are the package relative + # service names and values are the name to be used for the service client + # and call options. + # + # publishing: + # go_settings: + # renamed_services: + # Publisher: TopicAdmin + class GoSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class RenamedServicesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Describes the generator configuration for a method. + # @!attribute [rw] selector + # @return [::String] + # The fully qualified name of the method, for which the options below apply. + # This is used to find the method to apply the options. + # + # Example: + # + # publishing: + # method_settings: + # - selector: google.storage.control.v2.StorageControl.CreateFolder + # # method settings for CreateFolder... + # @!attribute [rw] long_running + # @return [::Google::Api::MethodSettings::LongRunning] + # Describes settings to use for long-running operations when generating + # API methods for RPCs. Complements RPCs that use the annotations in + # google/longrunning/operations.proto. + # + # Example of a YAML configuration:: + # + # publishing: + # method_settings: + # - selector: google.cloud.speech.v2.Speech.BatchRecognize + # long_running: + # initial_poll_delay: 60s # 1 minute + # poll_delay_multiplier: 1.5 + # max_poll_delay: 360s # 6 minutes + # total_poll_timeout: 54000s # 90 minutes + # @!attribute [rw] auto_populated_fields + # @return [::Array<::String>] + # List of top-level fields of the request message, that should be + # automatically populated by the client libraries based on their + # (google.api.field_info).format. Currently supported format: UUID4. + # + # Example of a YAML configuration: + # + # publishing: + # method_settings: + # - selector: google.example.v1.ExampleService.CreateExample + # auto_populated_fields: + # - request_id + class MethodSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Describes settings to use when generating API methods that use the + # long-running operation pattern. + # All default values below are from those used in the client library + # generators (e.g. + # [Java](https://github.com/googleapis/gapic-generator-java/blob/04c2faa191a9b5a10b92392fe8482279c4404803/src/main/java/com/google/api/generator/gapic/composer/common/RetrySettingsComposer.java)). + # @!attribute [rw] initial_poll_delay + # @return [::Google::Protobuf::Duration] + # Initial delay after which the first poll request will be made. + # Default value: 5 seconds. + # @!attribute [rw] poll_delay_multiplier + # @return [::Float] + # Multiplier to gradually increase delay between subsequent polls until it + # reaches max_poll_delay. + # Default value: 1.5. + # @!attribute [rw] max_poll_delay + # @return [::Google::Protobuf::Duration] + # Maximum time between two subsequent poll requests. + # Default value: 45 seconds. + # @!attribute [rw] total_poll_timeout + # @return [::Google::Protobuf::Duration] + # Total polling timeout. + # Default value: 5 minutes. + class LongRunning + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # This message is used to configure the generation of a subset of the RPCs in + # a service for client libraries. + # @!attribute [rw] methods + # @return [::Array<::String>] + # An allowlist of the fully qualified names of RPCs that should be included + # on public client surfaces. + # @!attribute [rw] generate_omitted_as_internal + # @return [::Boolean] + # Setting this to true indicates to the client generators that methods + # that would be excluded from the generation should instead be generated + # in a way that indicates these methods should not be consumed by + # end users. How this is expressed is up to individual language + # implementations to decide. Some examples may be: added annotations, + # obfuscated identifiers, or other language idiomatic patterns. + class SelectiveGapicGeneration + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The organization for which the client libraries are being published. + # Affects the url where generated docs are published, etc. + module ClientLibraryOrganization + # Not useful. + CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED = 0 + + # Google Cloud Platform Org. + CLOUD = 1 + + # Ads (Advertising) Org. + ADS = 2 + + # Photos Org. + PHOTOS = 3 + + # Street View Org. + STREET_VIEW = 4 + + # Shopping Org. + SHOPPING = 5 + + # Geo Org. + GEO = 6 + + # Generative AI - https://developers.generativeai.google + GENERATIVE_AI = 7 + end + + # To where should client libraries be published? + module ClientLibraryDestination + # Client libraries will neither be generated nor published to package + # managers. + CLIENT_LIBRARY_DESTINATION_UNSPECIFIED = 0 + + # Generate the client library in a repo under github.com/googleapis, + # but don't publish it to package managers. + GITHUB = 10 + + # Publish the library to package managers like nuget.org and npmjs.com. + PACKAGE_MANAGER = 20 + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb new file mode 100644 index 000000000000..582be187d115 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb @@ -0,0 +1,85 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # An indicator of the behavior of a given field (for example, that a field + # is required in requests, or given as output but ignored as input). + # This **does not** change the behavior in protocol buffers itself; it only + # denotes the behavior and may affect how API tooling handles the field. + # + # Note: This enum **may** receive new values in the future. + module FieldBehavior + # Conventional default for enums. Do not use this. + FIELD_BEHAVIOR_UNSPECIFIED = 0 + + # Specifically denotes a field as optional. + # While all fields in protocol buffers are optional, this may be specified + # for emphasis if appropriate. + OPTIONAL = 1 + + # Denotes a field as required. + # This indicates that the field **must** be provided as part of the request, + # and failure to do so will cause an error (usually `INVALID_ARGUMENT`). + REQUIRED = 2 + + # Denotes a field as output only. + # This indicates that the field is provided in responses, but including the + # field in a request does nothing (the server *must* ignore it and + # *must not* throw an error as a result of the field's presence). + OUTPUT_ONLY = 3 + + # Denotes a field as input only. + # This indicates that the field is provided in requests, and the + # corresponding field is not included in output. + INPUT_ONLY = 4 + + # Denotes a field as immutable. + # This indicates that the field may be set once in a request to create a + # resource, but may not be changed thereafter. + IMMUTABLE = 5 + + # Denotes that a (repeated) field is an unordered list. + # This indicates that the service may provide the elements of the list + # in any arbitrary order, rather than the order the user originally + # provided. Additionally, the list's order may or may not be stable. + UNORDERED_LIST = 6 + + # Denotes that this field returns a non-empty default value if not set. + # This indicates that if the user provides the empty value in a request, + # a non-empty value will be returned. The user will not be aware of what + # non-empty value to expect. + NON_EMPTY_DEFAULT = 7 + + # Denotes that the field in a resource (a message annotated with + # google.api.resource) is used in the resource name to uniquely identify the + # resource. For AIP-compliant APIs, this should only be applied to the + # `name` field on the resource. + # + # This behavior should not be applied to references to other resources within + # the message. + # + # The identifier field of resources often have different field behavior + # depending on the request it is embedded in (e.g. for Create methods name + # is optional and unused, while for Update methods it is required). Instead + # of method-specific annotations, only `IDENTIFIER` is required. + IDENTIFIER = 8 + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb new file mode 100644 index 000000000000..0f5acf0a5538 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb @@ -0,0 +1,88 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # Rich semantic information of an API field beyond basic typing. + # @!attribute [rw] format + # @return [::Google::Api::FieldInfo::Format] + # The standard format of a field value. This does not explicitly configure + # any API consumer, just documents the API's format for the field it is + # applied to. + # @!attribute [rw] referenced_types + # @return [::Array<::Google::Api::TypeReference>] + # The type(s) that the annotated, generic field may represent. + # + # Currently, this must only be used on fields of type `google.protobuf.Any`. + # Supporting other generic types may be considered in the future. + class FieldInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The standard format of a field value. The supported formats are all backed + # by either an RFC defined by the IETF or a Google-defined AIP. + module Format + # Default, unspecified value. + FORMAT_UNSPECIFIED = 0 + + # Universally Unique Identifier, version 4, value as defined by + # https://datatracker.ietf.org/doc/html/rfc4122. The value may be + # normalized to entirely lowercase letters. For example, the value + # `F47AC10B-58CC-0372-8567-0E02B2C3D479` would be normalized to + # `f47ac10b-58cc-0372-8567-0e02b2c3d479`. + UUID4 = 1 + + # Internet Protocol v4 value as defined by [RFC + # 791](https://datatracker.ietf.org/doc/html/rfc791). The value may be + # condensed, with leading zeros in each octet stripped. For example, + # `001.022.233.040` would be condensed to `1.22.233.40`. + IPV4 = 2 + + # Internet Protocol v6 value as defined by [RFC + # 2460](https://datatracker.ietf.org/doc/html/rfc2460). The value may be + # normalized to entirely lowercase letters with zeros compressed, following + # [RFC 5952](https://datatracker.ietf.org/doc/html/rfc5952). For example, + # the value `2001:0DB8:0::0` would be normalized to `2001:db8::`. + IPV6 = 3 + + # An IP address in either v4 or v6 format as described by the individual + # values defined herein. See the comments on the IPV4 and IPV6 types for + # allowed normalizations of each. + IPV4_OR_IPV6 = 4 + end + end + + # A reference to a message type, for use in {::Google::Api::FieldInfo FieldInfo}. + # @!attribute [rw] type_name + # @return [::String] + # The name of the type that the annotated, generic field may represent. + # If the type is in the same protobuf package, the value can be the simple + # message name e.g., `"MyMessage"`. Otherwise, the value must be the + # fully-qualified message name e.g., `"google.library.v1.Book"`. + # + # If the type(s) are unknown to the service (e.g. the field accepts generic + # user input), use the wildcard `"*"` to denote this behavior. + # + # See [AIP-202](https://google.aip.dev/202#type-references) for more details. + class TypeReference + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb new file mode 100644 index 000000000000..9392a413fb1b --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb @@ -0,0 +1,71 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # The launch stage as defined by [Google Cloud Platform + # Launch Stages](https://cloud.google.com/terms/launch-stages). + module LaunchStage + # Do not use this default value. + LAUNCH_STAGE_UNSPECIFIED = 0 + + # The feature is not yet implemented. Users can not use it. + UNIMPLEMENTED = 6 + + # Prelaunch features are hidden from users and are only visible internally. + PRELAUNCH = 7 + + # Early Access features are limited to a closed group of testers. To use + # these features, you must sign up in advance and sign a Trusted Tester + # agreement (which includes confidentiality provisions). These features may + # be unstable, changed in backward-incompatible ways, and are not + # guaranteed to be released. + EARLY_ACCESS = 1 + + # Alpha is a limited availability test for releases before they are cleared + # for widespread use. By Alpha, all significant design issues are resolved + # and we are in the process of verifying functionality. Alpha customers + # need to apply for access, agree to applicable terms, and have their + # projects allowlisted. Alpha releases don't have to be feature complete, + # no SLAs are provided, and there are no technical support obligations, but + # they will be far enough along that customers can actually use them in + # test environments or for limited-use tests -- just like they would in + # normal production cases. + ALPHA = 2 + + # Beta is the point at which we are ready to open a release for any + # customer to use. There are no SLA or technical support obligations in a + # Beta release. Products will be complete from a feature perspective, but + # may have some open outstanding issues. Beta releases are suitable for + # limited production use cases. + BETA = 3 + + # GA features are open to all developers and are considered stable and + # fully qualified for production use. + GA = 4 + + # Deprecated features are scheduled to be shut down and removed. For more + # information, see the "Deprecation Policy" section of our [Terms of + # Service](https://cloud.google.com/terms/) + # and the [Google Cloud Platform Subject to the Deprecation + # Policy](https://cloud.google.com/terms/deprecation) documentation. + DEPRECATED = 5 + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb new file mode 100644 index 000000000000..25dec4847ac1 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb @@ -0,0 +1,227 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # A simple descriptor of a resource type. + # + # ResourceDescriptor annotates a resource message (either by means of a + # protobuf annotation or use in the service config), and associates the + # resource's schema, the resource type, and the pattern of the resource name. + # + # Example: + # + # message Topic { + # // Indicates this message defines a resource schema. + # // Declares the resource type in the format of {service}/{kind}. + # // For Kubernetes resources, the format is {api group}/{kind}. + # option (google.api.resource) = { + # type: "pubsub.googleapis.com/Topic" + # pattern: "projects/{project}/topics/{topic}" + # }; + # } + # + # The ResourceDescriptor Yaml config will look like: + # + # resources: + # - type: "pubsub.googleapis.com/Topic" + # pattern: "projects/{project}/topics/{topic}" + # + # Sometimes, resources have multiple patterns, typically because they can + # live under multiple parents. + # + # Example: + # + # message LogEntry { + # option (google.api.resource) = { + # type: "logging.googleapis.com/LogEntry" + # pattern: "projects/{project}/logs/{log}" + # pattern: "folders/{folder}/logs/{log}" + # pattern: "organizations/{organization}/logs/{log}" + # pattern: "billingAccounts/{billing_account}/logs/{log}" + # }; + # } + # + # The ResourceDescriptor Yaml config will look like: + # + # resources: + # - type: 'logging.googleapis.com/LogEntry' + # pattern: "projects/{project}/logs/{log}" + # pattern: "folders/{folder}/logs/{log}" + # pattern: "organizations/{organization}/logs/{log}" + # pattern: "billingAccounts/{billing_account}/logs/{log}" + # @!attribute [rw] type + # @return [::String] + # The resource type. It must be in the format of + # \\{service_name}/\\{resource_type_kind}. The `resource_type_kind` must be + # singular and must not include version numbers. + # + # Example: `storage.googleapis.com/Bucket` + # + # The value of the resource_type_kind must follow the regular expression + # /[A-Za-z][a-zA-Z0-9]+/. It should start with an upper case character and + # should use PascalCase (UpperCamelCase). The maximum number of + # characters allowed for the `resource_type_kind` is 100. + # @!attribute [rw] pattern + # @return [::Array<::String>] + # Optional. The relative resource name pattern associated with this resource + # type. The DNS prefix of the full resource name shouldn't be specified here. + # + # The path pattern must follow the syntax, which aligns with HTTP binding + # syntax: + # + # Template = Segment { "/" Segment } ; + # Segment = LITERAL | Variable ; + # Variable = "{" LITERAL "}" ; + # + # Examples: + # + # - "projects/\\{project}/topics/\\{topic}" + # - "projects/\\{project}/knowledgeBases/\\{knowledge_base}" + # + # The components in braces correspond to the IDs for each resource in the + # hierarchy. It is expected that, if multiple patterns are provided, + # the same component name (e.g. "project") refers to IDs of the same + # type of resource. + # @!attribute [rw] name_field + # @return [::String] + # Optional. The field on the resource that designates the resource name + # field. If omitted, this is assumed to be "name". + # @!attribute [rw] history + # @return [::Google::Api::ResourceDescriptor::History] + # Optional. The historical or future-looking state of the resource pattern. + # + # Example: + # + # // The InspectTemplate message originally only supported resource + # // names with organization, and project was added later. + # message InspectTemplate { + # option (google.api.resource) = { + # type: "dlp.googleapis.com/InspectTemplate" + # pattern: + # "organizations/{organization}/inspectTemplates/{inspect_template}" + # pattern: "projects/{project}/inspectTemplates/{inspect_template}" + # history: ORIGINALLY_SINGLE_PATTERN + # }; + # } + # @!attribute [rw] plural + # @return [::String] + # The plural name used in the resource name and permission names, such as + # 'projects' for the resource name of 'projects/\\{project}' and the permission + # name of 'cloudresourcemanager.googleapis.com/projects.get'. One exception + # to this is for Nested Collections that have stuttering names, as defined + # in [AIP-122](https://google.aip.dev/122#nested-collections), where the + # collection ID in the resource name pattern does not necessarily directly + # match the `plural` value. + # + # It is the same concept of the `plural` field in k8s CRD spec + # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ + # + # Note: The plural form is required even for singleton resources. See + # https://aip.dev/156 + # @!attribute [rw] singular + # @return [::String] + # The same concept of the `singular` field in k8s CRD spec + # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ + # Such as "project" for the `resourcemanager.googleapis.com/Project` type. + # @!attribute [rw] style + # @return [::Array<::Google::Api::ResourceDescriptor::Style>] + # Style flag(s) for this resource. + # These indicate that a resource is expected to conform to a given + # style. See the specific style flags for additional information. + class ResourceDescriptor + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # A description of the historical or future-looking state of the + # resource pattern. + module History + # The "unset" value. + HISTORY_UNSPECIFIED = 0 + + # The resource originally had one pattern and launched as such, and + # additional patterns were added later. + ORIGINALLY_SINGLE_PATTERN = 1 + + # The resource has one pattern, but the API owner expects to add more + # later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents + # that from being necessary once there are multiple patterns.) + FUTURE_MULTI_PATTERN = 2 + end + + # A flag representing a specific style that a resource claims to conform to. + module Style + # The unspecified value. Do not use. + STYLE_UNSPECIFIED = 0 + + # This resource is intended to be "declarative-friendly". + # + # Declarative-friendly resources must be more strictly consistent, and + # setting this to true communicates to tools that this resource should + # adhere to declarative-friendly expectations. + # + # Note: This is used by the API linter (linter.aip.dev) to enable + # additional checks. + DECLARATIVE_FRIENDLY = 1 + end + end + + # Defines a proto annotation that describes a string field that refers to + # an API resource. + # @!attribute [rw] type + # @return [::String] + # The resource type that the annotated field references. + # + # Example: + # + # message Subscription { + # string topic = 2 [(google.api.resource_reference) = { + # type: "pubsub.googleapis.com/Topic" + # }]; + # } + # + # Occasionally, a field may reference an arbitrary resource. In this case, + # APIs use the special value * in their resource reference. + # + # Example: + # + # message GetIamPolicyRequest { + # string resource = 2 [(google.api.resource_reference) = { + # type: "*" + # }]; + # } + # @!attribute [rw] child_type + # @return [::String] + # The resource type of a child collection that the annotated field + # references. This is useful for annotating the `parent` field that + # doesn't have a fixed resource type. + # + # Example: + # + # message ListLogEntriesRequest { + # string parent = 1 [(google.api.resource_reference) = { + # child_type: "logging.googleapis.com/LogEntry" + # }; + # } + class ResourceReference + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb new file mode 100644 index 000000000000..72dcc5a8c215 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb @@ -0,0 +1,1209 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + # An order for GDC hardware. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] display_name + # @return [::String] + # Optional. Display name of this order. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this order was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this order was last updated. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this order as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [r] state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::State] + # Output only. State of this order. On order creation, state will be set to + # DRAFT. + # @!attribute [rw] organization_contact + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] + # Required. Customer contact information. + # @!attribute [rw] target_workloads + # @return [::Array<::String>] + # Optional. Customer specified workloads of interest targeted by this order. + # This must contain <= 20 elements and the length of each element must be <= + # 50 characters. + # @!attribute [rw] customer_motivation + # @return [::String] + # Required. Information about the customer's motivation for this order. The + # length of this field must be <= 1000 characters. + # @!attribute [rw] fulfillment_time + # @deprecated This field is deprecated and may be removed in the next major version update. + # @return [::Google::Protobuf::Timestamp] + # Deprecated: Please use customer_requested_installation_date instead. + # @!attribute [rw] customer_requested_installation_date + # @return [::Google::Type::Date] + # Optional. Customer requested installation date for this order. + # @!attribute [rw] region_code + # @return [::String] + # Required. [Unicode CLDR](http://cldr.unicode.org/) region code where this + # order will be deployed. For a list of valid CLDR region codes, see the + # [Language Subtag + # Registry](https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry). + # @!attribute [r] order_form_uri + # @return [::String] + # Output only. Link to the order form. + # @!attribute [r] type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::Type] + # Output only. Type of this Order. + # @!attribute [r] submit_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when the order was submitted. Is auto-populated to the + # current time when an order is submitted. + # @!attribute [r] billing_id + # @return [::String] + # Output only. The Google Cloud Billing ID to be charged for this order. + # @!attribute [rw] existing_hardware + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareLocation>] + # Optional. Existing hardware to be removed as part of this order. + # Note: any hardware removed will be recycled unless otherwise agreed. + # @!attribute [r] deployment_type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::DeploymentType] + # Output only. The deployment type of this order. + # @!attribute [r] actual_installation_date + # @return [::Google::Type::Date] + # Output only. Actual installation date for this order. + # @!attribute [r] estimated_installation_date + # @return [::Google::Type::Date] + # Output only. Estimated installation date for this order. + # @!attribute [r] estimated_delivery_date + # @return [::Google::Type::Date] + # Output only. Estimated delivery date for this order. + # @!attribute [rw] migration + # @return [::Boolean] + # Optional. Whether this order is a migration from customer's existing + # infrastructure. + # @!attribute [r] accepted_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time when the order was moved to ACCEPTED state. + # @!attribute [r] requested_date_change + # @return [::Google::Type::Date] + # Output only. The date to which the customer or Google wants to set the + # scheduled installation date. + # @!attribute [r] vendor_notes + # @return [::String] + # Output only. Notes for this order, provided by the vendor. + # @!attribute [r] vendor_contact + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] + # Output only. Contact information of the SI assigned to this order. + class Order + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Valid states of an order. + module State + # State of the order is unspecified. + STATE_UNSPECIFIED = 0 + + # Order is being drafted by the customer and has not been submitted yet. + DRAFT = 1 + + # Order has been submitted to Google. + SUBMITTED = 2 + + # All information required from the customer for fulfillment of the order + # is complete. + INFO_COMPLETE = 12 + + # Order has been accepted by Google. + ACCEPTED = 3 + + # Order needs more information from the customer. + ADDITIONAL_INFO_NEEDED = 4 + + # Google has initiated building hardware for the order. + BUILDING = 5 + + # The hardware has been built and is being shipped. + SHIPPING = 6 + + # The hardware is being installed. + INSTALLING = 7 + + # An error occurred in processing the order and customer intervention is + # required. + FAILED = 8 + + # Order has been partially completed i.e., some hardware have been + # delivered and installed. + PARTIALLY_COMPLETED = 9 + + # Order has been completed. + COMPLETED = 10 + + # Order has been cancelled. + CANCELLED = 11 + end + + # Valid types of an Order. + module Type + # Type of the order is unspecified. + TYPE_UNSPECIFIED = 0 + + # Paid by the customer. + PAID = 1 + + # Proof of concept for the customer. + POC = 2 + + # Not billed. + UNPAID = 2 + end + + # Valid types of a deployment. + module DeploymentType + # Deployment type is unspecified. + DEPLOYMENT_TYPE_UNSPECIFIED = 0 + + # Prod deployment with SLOs. + FULL_PRODUCTION = 1 + + # Deployment with best-effort support and no SLOs. + PROOF_OF_CONCEPT = 2 + + # Internal deployment with best-effort support and no SLOs. + INTERNAL = 3 + + # Customer lab deployment that we support as though it's prod. + CUSTOMER_LAB = 4 + end + end + + # A physical site where hardware will be installed. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @!attribute [rw] display_name + # @return [::String] + # Optional. Display name of this Site. + # @!attribute [rw] description + # @return [::String] + # Optional. Description of this Site. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this site was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this site was last updated. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this site as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [rw] organization_contact + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] + # Required. Contact information for this site. + # @!attribute [rw] google_maps_pin_uri + # @return [::String] + # Optional. A URL to the Google Maps address location of the site. + # An example value is `https://goo.gl/maps/xxxxxxxxx`. + # @!attribute [rw] access_times + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::TimePeriod>] + # Optional. The time periods when the site is accessible. + # If this field is empty, the site is accessible at all times. + # + # This field is used by Google to schedule the initial installation as well + # as any later hardware maintenance. You may update this at any time. For + # example, if the initial installation is requested during off-hours but + # maintenance should be performed during regular business hours, you should + # update the access times after initial installation is complete. + # @!attribute [rw] notes + # @return [::String] + # Optional. Any additional notes for this Site. Please include information + # about: + # - security or access restrictions + # - any regulations affecting the technicians visiting the site + # - any special process or approval required to move the equipment + # - whether a representative will be available during site visits + # @!attribute [rw] customer_site_id + # @return [::String] + # Optional. Customer defined identifier for this Site. This can be used to + # identify the site in the customer's own systems. + class Site + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # A group of hardware that is part of the same order, has the same SKU, and is + # delivered to the same site. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this hardware group was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this hardware group was last updated. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this hardware group as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [rw] hardware_count + # @return [::Integer] + # Required. Number of hardware in this HardwareGroup. + # @!attribute [rw] config + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareConfig] + # Required. Configuration for hardware in this HardwareGroup. + # @!attribute [rw] site + # @return [::String] + # Required. Name of the site where the hardware in this HardwareGroup will be + # delivered. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @!attribute [r] state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup::State] + # Output only. Current state of this HardwareGroup. + # @!attribute [rw] zone + # @return [::String] + # Optional. Name of the zone that the hardware in this HardwareGroup belongs + # to. Format: `projects/{project}/locations/{location}/zones/{zone}` + # @!attribute [rw] requested_installation_date + # @deprecated This field is deprecated and may be removed in the next major version update. + # @return [::Google::Type::Date] + # Deprecated: This value is not used. Use the requested_installation_date + # field in the Order resource instead. + class HardwareGroup + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Valid states of a HardwareGroup. + module State + # State of the HardwareGroup is unspecified. + STATE_UNSPECIFIED = 0 + + # More information is required from the customer to make progress. + ADDITIONAL_INFO_NEEDED = 1 + + # Google has initiated building hardware for this HardwareGroup. + BUILDING = 2 + + # The hardware has been built and is being shipped. + SHIPPING = 3 + + # The hardware is being installed. + INSTALLING = 4 + + # Some hardware in the HardwareGroup have been installed. + PARTIALLY_INSTALLED = 5 + + # All hardware in the HardwareGroup have been installed. + INSTALLED = 6 + + # An error occurred and customer intervention is required. + FAILED = 7 + end + end + + # An instance of hardware installed at a site. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # @!attribute [rw] display_name + # @return [::String] + # Optional. Display name for this hardware. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this hardware was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this hardware was last updated. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this hardware as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [rw] order + # @return [::String] + # Required. Name of the order that this hardware belongs to. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [r] hardware_group + # @return [::String] + # Output only. Name for the hardware group that this hardware belongs to. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @!attribute [rw] site + # @return [::String] + # Required. Name for the site that this hardware belongs to. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @!attribute [r] state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::State] + # Output only. Current state for this hardware. + # @!attribute [r] ciq_uri + # @return [::String] + # Output only. Link to the Customer Intake Questionnaire (CIQ) sheet for this + # Hardware. + # @!attribute [rw] config + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareConfig] + # Required. Configuration for this hardware. + # @!attribute [r] estimated_installation_date + # @return [::Google::Type::Date] + # Output only. Estimated installation date for this hardware. + # @!attribute [rw] physical_info + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo] + # Optional. Physical properties of this hardware. + # @!attribute [rw] installation_info + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareInstallationInfo] + # Optional. Information for installation of this hardware. + # @!attribute [rw] zone + # @return [::String] + # Required. Name for the zone that this hardware belongs to. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @!attribute [rw] requested_installation_date + # @return [::Google::Type::Date] + # Optional. Requested installation date for this hardware. If not specified, + # this is auto-populated from the order's fulfillment_time upon submission or + # from the HardwareGroup's requested_installation_date upon order acceptance. + # @!attribute [r] actual_installation_date + # @return [::Google::Type::Date] + # Output only. Actual installation date for this hardware. Filled in by + # Google. + # @!attribute [r] machine_infos + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MachineInfo>] + # Output only. Per machine asset information needed for turnup. + # @!attribute [r] estimated_delivery_date + # @return [::Google::Type::Date] + # Output only. The estimated delivery date of the hardware. + class Hardware + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Message to describe the MAC address of a machine. + # @!attribute [r] address + # @return [::String] + # Output only. Address string. + # @!attribute [r] type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MacAddress::AddressType] + # Output only. Address type for this MAC address. + # @!attribute [r] ipv4_address + # @return [::String] + # Output only. Static IP address (if used) that is associated with the MAC + # address. Only applicable for VIRTUAL MAC address type. + class MacAddress + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Enum for the different types of MAC address. + module AddressType + # Unspecified address type. + ADDRESS_TYPE_UNSPECIFIED = 0 + + # Address of a network interface card. + NIC = 1 + + # Address of a baseboard management controller. + BMC = 2 + + # Address of a virtual interface. + VIRTUAL = 3 + end + end + + # Information about individual disks on a machine. + # @!attribute [r] manufacturer + # @return [::String] + # Output only. Disk manufacturer. + # @!attribute [r] slot + # @return [::Integer] + # Output only. Disk slot number. + # @!attribute [r] serial_number + # @return [::String] + # Output only. Disk serial number. + # @!attribute [r] psid + # @return [::String] + # Output only. Disk PSID. + # @!attribute [r] part_number + # @return [::String] + # Output only. Disk part number. + # @!attribute [r] model_number + # @return [::String] + # Output only. Disk model number. + class DiskInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Information about individual machines vendors will provide during turnup. + # @!attribute [r] service_tag + # @return [::String] + # Output only. Machine service tag. + # @!attribute [r] mac_addresses + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MacAddress>] + # Output only. Each associated MAC address. + # @!attribute [r] name + # @return [::String] + # Output only. Machine name. + # @!attribute [r] disk_infos + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::DiskInfo>] + # Output only. Information for each disk installed. + class MachineInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Valid states for hardware. + module State + # State of the Hardware is unspecified. + STATE_UNSPECIFIED = 0 + + # More information is required from the customer to make progress. + ADDITIONAL_INFO_NEEDED = 1 + + # Google has initiated building hardware for this Hardware. + BUILDING = 2 + + # The hardware has been built and is being shipped. + SHIPPING = 3 + + # The hardware is being installed. + INSTALLING = 4 + + # The hardware has been installed. + INSTALLED = 5 + + # An error occurred and customer intervention is required. + FAILED = 6 + end + end + + # A comment on an order. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this comment was created. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this comment as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [r] author + # @return [::String] + # Output only. Username of the author of this comment. This is auto-populated + # from the credentials used during creation of the comment. + # @!attribute [rw] text + # @return [::String] + # Required. Text of this comment. The length of text must be <= 1000 + # characters. + # @!attribute [r] customer_viewed_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Timestamp of the first time this comment was viewed by the + # customer. If the comment wasn't viewed then this timestamp will be unset. + # @!attribute [r] author_entity + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Entity] + # Output only. The entity the author belongs to. + class Comment + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # A log entry of a change made to an order. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this change log entry. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this change log entry was created. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this change log entry as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [r] log + # @return [::String] + # Output only. Content of this log entry. + class ChangeLogEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # A stock keeping unit (SKU) of GDC hardware. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this SKU. + # Format: `projects/{project}/locations/{location}/skus/{sku}` + # @!attribute [r] display_name + # @return [::String] + # Output only. Display name of this SKU. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this SKU was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this SKU was last updated. + # @!attribute [r] config + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SkuConfig] + # Output only. Configuration for this SKU. + # @!attribute [r] instances + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::SkuInstance>] + # Output only. Available instances of this SKU. This field should be used for + # checking availability of a SKU. + # @!attribute [r] description + # @return [::String] + # Output only. Description of this SKU. + # @!attribute [r] revision_id + # @return [::String] + # Output only. The SKU revision ID. + # A new revision is created whenever `config` is updated. The format is an + # 8-character hexadecimal string. + # @!attribute [r] is_active + # @return [::Boolean] + # Output only. Flag to indicate whether or not this revision is active. Only + # an active revision can be used in a new Order. + # @!attribute [r] type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku::Type] + # Output only. Type of this SKU. + # @!attribute [r] vcpu_count + # @return [::Integer] + # Output only. The vCPU count associated with this SKU. + # @!attribute [r] hardware_count_ranges + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku::Range>] + # Output only. The inclusive ranges of hardware counts that are allowed in a + # zone using this SKU. + class Sku + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Inclusive range. + # @!attribute [rw] min + # @return [::Integer] + # The minimum value of the range. + # @!attribute [rw] max + # @return [::Integer] + # The maximum value of the range. + class Range + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Valid types of a SKU. + module Type + # Type of the SKU is unspecified. This is not an allowed value. + TYPE_UNSPECIFIED = 0 + + # Rack SKU. + RACK = 1 + + # Server SKU. + SERVER = 2 + end + end + + # A zone holding a set of hardware. + # @!attribute [rw] name + # @return [::String] + # Identifier. Name of this zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this zone was created. + # @!attribute [r] update_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Time when this zone was last updated. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels associated with this zone as key value pairs. + # For more information about labels, see [Create and manage + # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). + # @!attribute [rw] display_name + # @return [::String] + # Optional. Human friendly display name of this zone. + # @!attribute [r] state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone::State] + # Output only. Current state for this zone. + # @!attribute [rw] contacts + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Contact>] + # Required. The points of contact. + # @!attribute [r] ciq_uri + # @return [::String] + # Output only. Link to the Customer Intake Questionnaire (CIQ) sheet for this + # zone. + # @!attribute [rw] network_config + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ZoneNetworkConfig] + # Optional. Networking configuration for this zone. + # @!attribute [r] globally_unique_id + # @return [::String] + # Output only. Globally unique identifier generated for this Edge Zone. + # @!attribute [r] subscription_configs + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::SubscriptionConfig>] + # Output only. Subscription configurations for this zone. + # @!attribute [r] provisioning_state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone::ProvisioningState] + # Output only. Provisioning state for configurations like MAC addresses. + # @!attribute [rw] skip_cluster_provisioning + # @return [::Boolean] + # Optional. Whether to skip the cluster provisioning step during factory + # turnup. If true, indicates that the Kubernetes cluster will be created + # after the zone's hardware is installed at the customer site. + # @!attribute [r] cluster_intent_required + # @return [::Boolean] + # Output only. Indicates whether a valid cluster intent must be provided by + # the customer before accepting the order. If true, the order cannot be + # accepted until cluster intent is present. This is used to enforce early + # validation and prevent delays caused by missing configuration. + # @!attribute [r] cluster_intent_verified + # @return [::Boolean] + # Output only. Indicates whether the provided cluster intent has been + # successfully verified. This flag ensures cluster intent exists before order + # can be accepted. + class Zone + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Valid states for a zone. + module State + # State of the Zone is unspecified. + STATE_UNSPECIFIED = 0 + + # More information is required from the customer to make progress. + ADDITIONAL_INFO_NEEDED = 1 + + # Google is preparing the Zone. + PREPARING = 2 + + # Factory turnup has succeeded. + READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS = 5 + + # The Zone is running factory turnup checks. + CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED = 8 + + # The Zone is ready for site turnup. + READY_FOR_SITE_TURNUP = 6 + + # The Zone is offline. + OFFLINE = 9 + + # The Zone failed in factory turnup checks. + CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED = 7 + + # The Zone is available to use. + ACTIVE = 3 + + # The Zone has been cancelled. + CANCELLED = 4 + end + + # Valid provisioning states for configurations like MAC addresses. + module ProvisioningState + # Provisioning state is unspecified. + PROVISIONING_STATE_UNSPECIFIED = 0 + + # Provisioning is required. Set by Google. + PROVISIONING_REQUIRED = 1 + + # Provisioning is in progress. Set by customer. + PROVISIONING_IN_PROGRESS = 2 + + # Provisioning is complete. Set by customer. + PROVISIONING_COMPLETE = 3 + end + end + + # Contact information of the customer organization. + # @!attribute [rw] address + # @return [::Google::Type::PostalAddress] + # Required. The organization's address. + # @!attribute [rw] email + # @return [::String] + # Optional. The organization's email. + # @!attribute [rw] phone + # @return [::String] + # Optional. The organization's phone number. + # @!attribute [rw] contacts + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Contact>] + # Required. The individual points of contact in the organization at this + # location. + class OrganizationContact + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Contact details of a point of contact. + # @!attribute [rw] given_name + # @return [::String] + # Required. Given name of the contact. + # @!attribute [rw] family_name + # @return [::String] + # Optional. Family name of the contact. + # @!attribute [rw] email + # @return [::String] + # Required. Email of the contact. + # @!attribute [rw] phone + # @return [::String] + # Required. Phone number of the contact. + # @!attribute [rw] time_zone + # @return [::Google::Type::TimeZone] + # Optional. Time zone of the contact. + # @!attribute [rw] reachable_times + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::TimePeriod>] + # Optional. The time periods when the contact is reachable. + # If this field is empty, the contact is reachable at all times. + class Contact + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Configuration for GDC hardware. + # @!attribute [rw] sku + # @return [::String] + # Required. Reference to the SKU for this hardware. This can point to a + # specific SKU revision in the form of `resource_name@revision_id` as defined + # in [AIP-162](https://google.aip.dev/162). If no revision_id is specified, + # it refers to the latest revision. + # @!attribute [rw] power_supply + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::PowerSupply] + # Required. Power supply type for this hardware. + # @!attribute [rw] subscription_duration_months + # @return [::Integer] + # Optional. Subscription duration for the hardware in months. + class HardwareConfig + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Configuration for a SKU. + # @!attribute [rw] cpu + # @return [::String] + # Information about CPU configuration. + # @!attribute [rw] gpu + # @return [::String] + # Information about GPU configuration. + # @!attribute [rw] ram + # @return [::String] + # Information about RAM configuration. + # @!attribute [rw] storage + # @return [::String] + # Information about storage configuration. + class SkuConfig + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A specific instance of the SKU. + # @!attribute [rw] region_code + # @return [::String] + # The [Unicode CLDR](https://cldr.unicode.org) region code where this + # instance is available. + # @!attribute [rw] power_supply + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::PowerSupply] + # Power supply type for this instance. + # @!attribute [rw] billing_sku + # @return [::String] + # Reference to the corresponding SKU in the Cloud Billing API. + # The estimated price information can be retrieved using that API. + # Format: `services/{service}/skus/{sku}` + # @!attribute [rw] billing_sku_per_vcpu + # @return [::String] + # Reference to the corresponding SKU per vCPU in the Cloud Billing API. + # The estimated price information can be retrieved using that API. + # Format: `services/{service}/skus/{sku}` + # @!attribute [rw] subscription_duration_months + # @return [::Integer] + # Subscription duration for the hardware in months. + class SkuInstance + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Physical properties of a hardware. + # @!attribute [rw] power_receptacle + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::PowerReceptacleType] + # Required. The power receptacle type. + # @!attribute [rw] network_uplink + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::NetworkUplinkType] + # Required. Type of the uplink network connection. + # @!attribute [rw] voltage + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::Voltage] + # Required. Voltage of the power supply. + # @!attribute [rw] amperes + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::Amperes] + # Required. Amperes of the power supply. + class HardwarePhysicalInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Valid power receptacle types. + module PowerReceptacleType + # Facility plug type is unspecified. + POWER_RECEPTACLE_TYPE_UNSPECIFIED = 0 + + # NEMA 5-15. + NEMA_5_15 = 1 + + # C13. + C_13 = 2 + + # Deprecated: Please use TYPE_G_BS1363, CEE_7_3, CEE_7_5 or TYPE_F + # instead. + STANDARD_EU = 3 + + # Type G / BS1363. + TYPE_G_BS1363 = 4 + + # C 7/3. + CEE_7_3 = 5 + + # C 7/5. + CEE_7_5 = 6 + + # Type F. + TYPE_F = 7 + end + + # Valid network uplink types. + module NetworkUplinkType + # Network uplink type is unspecified. + NETWORK_UPLINK_TYPE_UNSPECIFIED = 0 + + # RJ-45. + RJ_45 = 1 + end + + # Valid voltage values. + module Voltage + # Voltage is unspecified. + VOLTAGE_UNSPECIFIED = 0 + + # 120V. + VOLTAGE_110 = 1 + + # 220V. + VOLTAGE_220 = 3 + end + + # Valid amperes values. + module Amperes + # Amperes is unspecified. + AMPERES_UNSPECIFIED = 0 + + # 15A. + AMPERES_15 = 1 + end + end + + # Information for installation of a Hardware. + # @!attribute [rw] rack_location + # @return [::String] + # Required. Location of the rack in the site e.g. Floor 2, Room 201, Row 7, + # Rack 3. + # @!attribute [rw] power_distance_meters + # @return [::Integer] + # Required. Distance from the power outlet in meters. + # @!attribute [rw] switch_distance_meters + # @return [::Integer] + # Required. Distance from the network switch in meters. + # @!attribute [rw] rack_unit_dimensions + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Dimensions] + # Required. Dimensions of the rack unit. + # @!attribute [rw] rack_space + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::RackSpace] + # Required. Rack space allocated for the hardware. + # @!attribute [rw] rack_type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareInstallationInfo::RackType] + # Required. Type of the rack. + class HardwareInstallationInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Valid rack types. + module RackType + # Rack type is unspecified. + RACK_TYPE_UNSPECIFIED = 0 + + # Two post rack. + TWO_POST = 1 + + # Four post rack. + FOUR_POST = 2 + end + end + + # Networking configuration for a zone. + # @!attribute [rw] machine_mgmt_ipv4_range + # @return [::String] + # Required. An IPv4 address block for machine management. + # Should be a private RFC1918 or public CIDR block large enough to allocate + # at least one address per machine in the Zone. + # Should be in `management_ipv4_subnet`, and disjoint with other address + # ranges. + # @!attribute [rw] kubernetes_node_ipv4_range + # @return [::String] + # Required. An IPv4 address block for kubernetes nodes. + # Should be a private RFC1918 or public CIDR block large enough to allocate + # at least one address per machine in the Zone. + # Should be in `kubernetes_ipv4_subnet`, and disjoint with other address + # ranges. + # @!attribute [rw] kubernetes_control_plane_ipv4_range + # @return [::String] + # Required. An IPv4 address block for kubernetes control plane. + # Should be a private RFC1918 or public CIDR block large enough to allocate + # at least one address per cluster in the Zone. + # Should be in `kubernetes_ipv4_subnet`, and disjoint with other address + # ranges. + # @!attribute [rw] management_ipv4_subnet + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Subnet] + # Required. An IPv4 subnet for the management network. + # @!attribute [rw] kubernetes_ipv4_subnet + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Subnet] + # Optional. An IPv4 subnet for the kubernetes network. + # If unspecified, the kubernetes subnet will be the same as the management + # subnet. + # @!attribute [rw] dns_ipv4_addresses + # @return [::Array<::String>] + # Optional. DNS nameservers. + # The GDC Infrastructure will resolve DNS queries via these IPs. + # If unspecified, Google DNS is used. + # @!attribute [rw] kubernetes_primary_vlan_id + # @return [::Integer] + # Optional. Kubernetes VLAN ID. + # By default, the kubernetes node, including the primary kubernetes network, + # are in the same VLAN as the machine management network. + # For network segmentation purposes, these can optionally be separated. + class ZoneNetworkConfig + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents a subnet. + # @!attribute [rw] address_range + # @return [::String] + # Required. Address range for this subnet in CIDR notation. + # @!attribute [rw] default_gateway_ip_address + # @return [::String] + # Required. Default gateway for this subnet. + class Subnet + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents a time period in a week. + # @!attribute [rw] start_time + # @return [::Google::Type::TimeOfDay] + # Required. The start of the time period. + # @!attribute [rw] end_time + # @return [::Google::Type::TimeOfDay] + # Required. The end of the time period. + # @!attribute [rw] days + # @return [::Array<::Google::Type::DayOfWeek>] + # Required. The days of the week that the time period is active. + class TimePeriod + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents the dimensions of an object. + # @!attribute [rw] width_inches + # @return [::Float] + # Required. Width in inches. + # @!attribute [rw] height_inches + # @return [::Float] + # Required. Height in inches. + # @!attribute [rw] depth_inches + # @return [::Float] + # Required. Depth in inches. + class Dimensions + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents contiguous space in a rack. + # @!attribute [rw] start_rack_unit + # @return [::Integer] + # Required. First rack unit of the rack space (inclusive). + # @!attribute [rw] end_rack_unit + # @return [::Integer] + # Required. Last rack unit of the rack space (inclusive). + class RackSpace + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents the location of one or many hardware. + # @!attribute [rw] site + # @return [::String] + # Required. Name of the site where the hardware are present. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @!attribute [rw] rack_location + # @return [::String] + # Required. Location of the rack in the site e.g. Floor 2, Room 201, Row 7, + # Rack 3. + # @!attribute [rw] rack_space + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::RackSpace>] + # Optional. Spaces occupied by the hardware in the rack. + # If unset, this location is assumed to be the entire rack. + class HardwareLocation + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A message to store a subscription configuration. + # @!attribute [r] subscription_id + # @return [::String] + # Output only. The unique identifier of the subscription. + # @!attribute [r] billing_id + # @return [::String] + # Output only. The Google Cloud Billing ID that the subscription is created + # under. + # @!attribute [r] state + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SubscriptionConfig::SubscriptionState] + # Output only. The current state of the subscription. + class SubscriptionConfig + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Enum to represent the state of the subscription. + module SubscriptionState + # State is unspecified. + SUBSCRIPTION_STATE_UNSPECIFIED = 0 + + # Active state means that the subscription has been created successfully + # and billing is happening. + ACTIVE = 1 + + # Inactive means that the subscription has been created successfully, but + # billing has not started yet. + INACTIVE = 2 + + # The subscription is in an erroneous state. + ERROR = 3 + + # The subscription state failed to be retrieved. This may be a transient + # issue. The user should retry the request. + FAILED_TO_RETRIEVE = 4 + + # The subscription has been completed, because it has reached the end date. + COMPLETED = 5 + end + end + + # The power supply options. + module PowerSupply + # Power supply is unspecified. + POWER_SUPPLY_UNSPECIFIED = 0 + + # AC power supply. + POWER_SUPPLY_AC = 1 + + # DC power supply. + POWER_SUPPLY_DC = 2 + end + + # Entity is used to denote an organization or party. + module Entity + # Entity is unspecified. + ENTITY_UNSPECIFIED = 0 + + # Google. + GOOGLE = 1 + + # Customer. + CUSTOMER = 2 + + # Vendor. + VENDOR = 3 + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb new file mode 100644 index 000000000000..cf335ddab76c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb @@ -0,0 +1,959 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module GDCHardwareManagement + module V1alpha + # A request to list orders. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to list orders in. + # Format: `projects/{project}/locations/{location}` + # + # To list orders across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListOrdersRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of orders. + # @!attribute [rw] orders + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] + # The list of orders. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. Only used for queries to the wildcard + # location `-`. If non-empty, it indicates that the results are incomplete. + class ListOrdersResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get an order. + # @!attribute [rw] name + # @return [::String] + # Required. Name of the resource + class GetOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create an order. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to create the order in. + # Format: `projects/{project}/locations/{location}` + # @!attribute [rw] order_id + # @return [::String] + # Optional. ID used to uniquely identify the Order within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The order.name field in the request will be ignored. + # @!attribute [rw] order + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # Required. The order to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CreateOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to update an order. + # @!attribute [rw] update_mask + # @return [::Google::Protobuf::FieldMask] + # Required. A mask to specify the fields in the Order to overwrite with this + # update. The fields specified in the update_mask are relative to the order, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @!attribute [rw] order + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] + # Required. The order to update. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class UpdateOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to delete an order. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @!attribute [rw] force + # @return [::Boolean] + # Optional. An option to delete any nested resources in the Order, such as a + # HardwareGroup. If true, any nested resources for this Order will also be + # deleted. Otherwise, the request will only succeed if the Order has no + # nested resources. + class DeleteOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to submit an order. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @!attribute [rw] type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] + # Optional. Type of this request. If unset, the request type is assumed to be + # `INFO_PENDING`. + class SubmitOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Valid types of submit order request. + module Type + # Request type is unspecified. This should not be used. + TYPE_UNSPECIFIED = 0 + + # Use this request type to submit your order and initiate conversation with + # Google. After this submission, you will not be able to modify the number + # or SKU of your ordered hardware. Please note that this order will not be + # ready for fulfillment yet until you provide more information, such as + # zone network configuration, hardware physical and installation + # information, etc. + # If you are submitting an order for a SKU type of RACK, please use this + # request type, as additional information will be required outside of the + # API. + INFO_PENDING = 1 + + # Use this request type if and when you are ready to submit your order for + # fulfillment. In addition to the information required for `INFO_PENDING`, + # the order must contain all required information, such as zone network + # configuration, hardware physical and installation information, etc. + # Further changes to any order information will no longer be allowed. + INFO_COMPLETE = 2 + end + end + + # A request to cancel an order. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the order. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CancelOrderRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list sites. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to list sites in. + # Format: `projects/{project}/locations/{location}` + # + # To list sites across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListSitesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of sites. + # @!attribute [rw] sites + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] + # The list of sites. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. Only used for queries to the wildcard + # location `-`. If non-empty, it indicates that the results are incomplete. + class ListSitesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get a site. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + class GetSiteRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create a site. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to create the site in. + # Format: `projects/{project}/locations/{location}` + # @!attribute [rw] site_id + # @return [::String] + # Optional. ID used to uniquely identify the Site within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The site.name field in the request will be ignored. + # @!attribute [rw] site + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # Required. The site to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CreateSiteRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to update a site. + # @!attribute [rw] update_mask + # @return [::Google::Protobuf::FieldMask] + # Required. A mask to specify the fields in the Site to overwrite with this + # update. The fields specified in the update_mask are relative to the site, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @!attribute [rw] site + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] + # Required. The site to update. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class UpdateSiteRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to delete a site. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the site. + # Format: `projects/{project}/locations/{location}/sites/{site}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class DeleteSiteRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list hardware groups. + # @!attribute [rw] parent + # @return [::String] + # Required. The order to list hardware groups in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListHardwareGroupsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of hardware groups. + # @!attribute [rw] hardware_groups + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] + # The list of hardware groups. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. + class ListHardwareGroupsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get a hardware group. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + class GetHardwareGroupRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create a hardware group. + # @!attribute [rw] parent + # @return [::String] + # Required. The order to create the hardware group in. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] hardware_group_id + # @return [::String] + # Optional. ID used to uniquely identify the HardwareGroup within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware_group.name field in the request will be ignored. + # @!attribute [rw] hardware_group + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # Required. The hardware group to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CreateHardwareGroupRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to update a hardware group. + # @!attribute [rw] update_mask + # @return [::Google::Protobuf::FieldMask] + # Required. A mask to specify the fields in the HardwareGroup to overwrite + # with this update. The fields specified in the update_mask are relative to + # the hardware group, not the full request. A field will be overwritten if it + # is in the mask. If you don't provide a mask then all fields will be + # overwritten. + # @!attribute [rw] hardware_group + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] + # Required. The hardware group to update. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class UpdateHardwareGroupRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to delete a hardware group. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the hardware group. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class DeleteHardwareGroupRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list hardware. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to list hardware in. + # Format: `projects/{project}/locations/{location}` + # + # To list hardware across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListHardwareRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of hardware. + # @!attribute [rw] hardware + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] + # The list of hardware. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. Only used for queries to the wildcard + # location `-`. If non-empty, it indicates that the results are incomplete. + class ListHardwareResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get hardware. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + class GetHardwareRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create hardware. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to create hardware in. + # Format: `projects/{project}/locations/{location}` + # @!attribute [rw] hardware_id + # @return [::String] + # Optional. ID used to uniquely identify the Hardware within its parent + # scope. This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The hardware.name field in the request will be ignored. + # @!attribute [rw] hardware + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # Required. The resource to create. + class CreateHardwareRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to update hardware. + # @!attribute [rw] update_mask + # @return [::Google::Protobuf::FieldMask] + # Required. A mask to specify the fields in the Hardware to overwrite with + # this update. The fields specified in the update_mask are relative to the + # hardware, not the full request. A field will be overwritten if it is in the + # mask. If you don't provide a mask then all fields will be overwritten. + # @!attribute [rw] hardware + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] + # Required. The hardware to update. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class UpdateHardwareRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to delete hardware. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the hardware. + # Format: `projects/{project}/locations/{location}/hardware/{hardware}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class DeleteHardwareRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list comments. + # @!attribute [rw] parent + # @return [::String] + # Required. The order to list comments on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListCommentsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list comments. + # @!attribute [rw] comments + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] + # The list of comments. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. + class ListCommentsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get a comment. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + class GetCommentRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create a comment. + # @!attribute [rw] parent + # @return [::String] + # Required. The order to create the comment on. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] comment_id + # @return [::String] + # Optional. ID used to uniquely identify the Comment within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The comment.name field in the request will be ignored. + # @!attribute [rw] comment + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] + # Required. The comment to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CreateCommentRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to record an action on a comment. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the comment. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` + # @!attribute [rw] action_type + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] + # Required. The action type of the recorded action. + class RecordActionOnCommentRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Valid action types of Comment. + module ActionType + # Action is unspecified. + ACTION_TYPE_UNSPECIFIED = 0 + + # Mark comment as read. + READ = 1 + + # Mark comment as unread. + UNREAD = 2 + end + end + + # A request to list change log entries. + # @!attribute [rw] parent + # @return [::String] + # Required. The order to list change log entries for. + # Format: `projects/{project}/locations/{location}/orders/{order}` + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListChangeLogEntriesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of change log entries. + # @!attribute [rw] change_log_entries + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] + # The list of change log entries. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. + class ListChangeLogEntriesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get a change log entry. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the change log entry. + # Format: + # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` + class GetChangeLogEntryRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list SKUs. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to list SKUs in. + # Format: `projects/{project}/locations/{location}` + # + # To list SKUs across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListSkusRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of SKUs. + # @!attribute [rw] skus + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] + # The list of SKUs. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. Only used for queries to the wildcard + # location `-`. If non-empty, it indicates that the results are incomplete. + class ListSkusResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get an SKU. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the SKU. + # Format: `projects/{project}/locations/{location}/skus/{sku}` + class GetSkuRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to list zones. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to list zones in. + # Format: `projects/{project}/locations/{location}` + # + # To list zones across all locations, substitute `-` (the hyphen or + # dash character) for the location and check the unreachable field in + # the response message. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. Requested page size. Server may return fewer items than + # requested. If unspecified, server will pick an appropriate default. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). + # @!attribute [rw] order_by + # @return [::String] + # Optional. Hint for how to order the results. + class ListZonesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A list of zones. + # @!attribute [rw] zones + # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] + # The list of zones. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Locations that could not be reached. Only used for queries to the wildcard + # location `-`. If non-empty, it indicates that the results are incomplete. + class ListZonesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to get a zone. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + class GetZoneRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to create a zone. + # @!attribute [rw] parent + # @return [::String] + # Required. The project and location to create the zone in. + # Format: `projects/{project}/locations/{location}` + # @!attribute [rw] zone_id + # @return [::String] + # Optional. ID used to uniquely identify the Zone within its parent scope. + # This field should contain at most 63 characters and must start with + # lowercase characters. + # Only lowercase characters, numbers and `-` are accepted. + # The `-` character cannot be the first or the last one. + # A system generated ID will be used if the field is not set. + # + # The zone.name field in the request will be ignored. + # @!attribute [rw] zone + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # Required. The zone to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class CreateZoneRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to update a zone. + # @!attribute [rw] update_mask + # @return [::Google::Protobuf::FieldMask] + # Required. A mask to specify the fields in the Zone to overwrite with this + # update. The fields specified in the update_mask are relative to the zone, + # not the full request. A field will be overwritten if it is in the mask. If + # you don't provide a mask then all fields will be overwritten. + # @!attribute [rw] zone + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] + # Required. The zone to update. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class UpdateZoneRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to delete a zone. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + class DeleteZoneRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to signal the state of a zone. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the zone. + # Format: `projects/{project}/locations/{location}/zones/{zone}` + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional unique identifier for this request. See + # [AIP-155](https://google.aip.dev/155). + # @!attribute [rw] state_signal + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] + # Optional. The state signal to send for this zone. Either state_signal or + # provisioning_state_signal must be set, but not both. + # @!attribute [rw] provisioning_state_signal + # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] + # Optional. The provisioning state signal to send for this zone. Either + # state_signal or provisioning_state_signal must be set, but not both. + # @!attribute [rw] step + # @return [::String] + # Optional. The step being executed. Provides a finer grained status when the + # state_signal is FACTORY_TURNUP_CHECKS_STARTED or + # FACTORY_TURNUP_CHECKS_FAILED. + # @!attribute [rw] details + # @return [::String] + # Optional. Additional details, such as an error message when state_signal is + # FACTORY_TURNUP_CHECKS_FAILED. + class SignalZoneStateRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Valid state signals for a zone. + module StateSignal + # State signal of the zone is unspecified. + STATE_SIGNAL_UNSPECIFIED = 0 + + # Factory turnup checks have started. + FACTORY_TURNUP_CHECKS_STARTED = 3 + + # The Zone is ready for site turnup. + FACTORY_TURNUP_CHECKS_PASSED = 1 + + # The Zone is ready for site turnup. Deprecated, but not deleted. + READY_FOR_SITE_TURNUP = 1 + + # The Zone failed in factory turnup checks. + FACTORY_TURNUP_CHECKS_FAILED = 2 + + # Verify that a valid cluster intent is present. + VERIFY_CLUSTER_INTENT_PRESENCE = 4 + end + + # Valid provisioning state signals for a zone. + module ProvisioningStateSignal + # Provisioning state signal is unspecified. + PROVISIONING_STATE_SIGNAL_UNSPECIFIED = 0 + + # Provisioning is in progress. + PROVISIONING_IN_PROGRESS = 1 + + # Provisioning is complete. + PROVISIONING_COMPLETE = 2 + end + end + + # Represents the metadata of a long-running operation. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time the operation was created. + # @!attribute [r] end_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time the operation finished running. + # @!attribute [r] target + # @return [::String] + # Output only. Server-defined resource path for the target of the operation. + # @!attribute [r] verb + # @return [::String] + # Output only. The verb executed by the operation. + # @!attribute [r] status_message + # @return [::String] + # Output only. Human-readable status of the operation, if any. + # @!attribute [r] requested_cancellation + # @return [::Boolean] + # Output only. Identifies whether the user has requested cancellation + # of the operation. Operations that have been cancelled successfully + # have [Operation.error][] value with a + # {::Google::Rpc::Status#code google.rpc.Status.code} of 1, corresponding to + # `Code.CANCELLED`. + # @!attribute [r] api_version + # @return [::String] + # Output only. API version used to start the operation. + class OperationMetadata + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A request to change the requested date of an order. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the order to update. + # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} + # @!attribute [rw] requested_date + # @return [::Google::Type::Date] + # Required. The date to which the customer or Google wants to set the + # scheduled installation date. + class RequestOrderDateChangeRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb new file mode 100644 index 000000000000..7a757f512165 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb @@ -0,0 +1,191 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Longrunning + # This resource represents a long-running operation that is the result of a + # network API call. + # @!attribute [rw] name + # @return [::String] + # The server-assigned name, which is only unique within the same service that + # originally returns it. If you use the default HTTP mapping, the + # `name` should be a resource name ending with `operations/{unique_id}`. + # @!attribute [rw] metadata + # @return [::Google::Protobuf::Any] + # Service-specific metadata associated with the operation. It typically + # contains progress information and common metadata such as create time. + # Some services might not provide such metadata. Any method that returns a + # long-running operation should document the metadata type, if any. + # @!attribute [rw] done + # @return [::Boolean] + # If the value is `false`, it means the operation is still in progress. + # If `true`, the operation is completed, and either `error` or `response` is + # available. + # @!attribute [rw] error + # @return [::Google::Rpc::Status] + # The error result of the operation in case of failure or cancellation. + # + # Note: The following fields are mutually exclusive: `error`, `response`. If a field in that set is populated, all other fields in the set will automatically be cleared. + # @!attribute [rw] response + # @return [::Google::Protobuf::Any] + # The normal, successful response of the operation. If the original + # method returns no data on success, such as `Delete`, the response is + # `google.protobuf.Empty`. If the original method is standard + # `Get`/`Create`/`Update`, the response should be the resource. For other + # methods, the response should have the type `XxxResponse`, where `Xxx` + # is the original method name. For example, if the original method name + # is `TakeSnapshot()`, the inferred response type is + # `TakeSnapshotResponse`. + # + # Note: The following fields are mutually exclusive: `response`, `error`. If a field in that set is populated, all other fields in the set will automatically be cleared. + class Operation + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for + # Operations.GetOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource. + class GetOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for + # Operations.ListOperations. + # @!attribute [rw] name + # @return [::String] + # The name of the operation's parent resource. + # @!attribute [rw] filter + # @return [::String] + # The standard list filter. + # @!attribute [rw] page_size + # @return [::Integer] + # The standard list page size. + # @!attribute [rw] page_token + # @return [::String] + # The standard list page token. + # @!attribute [rw] return_partial_success + # @return [::Boolean] + # When set to `true`, operations that are reachable are returned as normal, + # and those that are unreachable are returned in the + # [ListOperationsResponse.unreachable] field. + # + # This can only be `true` when reading across collections e.g. when `parent` + # is set to `"projects/example/locations/-"`. + # + # This field is not by default supported and will result in an + # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in + # service or product specific documentation. + class ListOperationsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response message for + # Operations.ListOperations. + # @!attribute [rw] operations + # @return [::Array<::Google::Longrunning::Operation>] + # A list of operations that matches the specified filter in the request. + # @!attribute [rw] next_page_token + # @return [::String] + # The standard List next-page token. + # @!attribute [rw] unreachable + # @return [::Array<::String>] + # Unordered list. Unreachable resources. Populated when the request sets + # `ListOperationsRequest.return_partial_success` and reads across + # collections e.g. when attempting to list all resources across all supported + # locations. + class ListOperationsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for + # Operations.CancelOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to be cancelled. + class CancelOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for + # Operations.DeleteOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to be deleted. + class DeleteOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for + # Operations.WaitOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to wait on. + # @!attribute [rw] timeout + # @return [::Google::Protobuf::Duration] + # The maximum duration to wait before timing out. If left blank, the wait + # will be at most the time permitted by the underlying HTTP/RPC protocol. + # If RPC context deadline is also specified, the shorter one will be used. + class WaitOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A message representing the message types used by a long-running operation. + # + # Example: + # + # rpc Export(ExportRequest) returns (google.longrunning.Operation) { + # option (google.longrunning.operation_info) = { + # response_type: "ExportResponse" + # metadata_type: "ExportMetadata" + # }; + # } + # @!attribute [rw] response_type + # @return [::String] + # Required. The message name of the primary return type for this + # long-running operation. + # This type will be used to deserialize the LRO's response. + # + # If the response is in a different package from the rpc, a fully-qualified + # message name must be used (e.g. `google.protobuf.Struct`). + # + # Note: Altering this value constitutes a breaking change. + # @!attribute [rw] metadata_type + # @return [::String] + # Required. The message name of the metadata type for this long-running + # operation. + # + # If the response is in a different package from the rpc, a fully-qualified + # message name must be used (e.g. `google.protobuf.Struct`). + # + # Note: Altering this value constitutes a breaking change. + class OperationInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb new file mode 100644 index 000000000000..58691995f02e --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb @@ -0,0 +1,145 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # `Any` contains an arbitrary serialized protocol buffer message along with a + # URL that describes the type of the serialized message. + # + # Protobuf library provides support to pack/unpack Any values in the form + # of utility functions or additional generated methods of the Any type. + # + # Example 1: Pack and unpack a message in C++. + # + # Foo foo = ...; + # Any any; + # any.PackFrom(foo); + # ... + # if (any.UnpackTo(&foo)) { + # ... + # } + # + # Example 2: Pack and unpack a message in Java. + # + # Foo foo = ...; + # Any any = Any.pack(foo); + # ... + # if (any.is(Foo.class)) { + # foo = any.unpack(Foo.class); + # } + # // or ... + # if (any.isSameTypeAs(Foo.getDefaultInstance())) { + # foo = any.unpack(Foo.getDefaultInstance()); + # } + # + # Example 3: Pack and unpack a message in Python. + # + # foo = Foo(...) + # any = Any() + # any.Pack(foo) + # ... + # if any.Is(Foo.DESCRIPTOR): + # any.Unpack(foo) + # ... + # + # Example 4: Pack and unpack a message in Go + # + # foo := &pb.Foo{...} + # any, err := anypb.New(foo) + # if err != nil { + # ... + # } + # ... + # foo := &pb.Foo{} + # if err := any.UnmarshalTo(foo); err != nil { + # ... + # } + # + # The pack methods provided by protobuf library will by default use + # 'type.googleapis.com/full.type.name' as the type URL and the unpack + # methods only use the fully qualified type name after the last '/' + # in the type URL, for example "foo.bar.com/x/y.z" will yield type + # name "y.z". + # + # JSON + # ==== + # The JSON representation of an `Any` value uses the regular + # representation of the deserialized, embedded message, with an + # additional field `@type` which contains the type URL. Example: + # + # package google.profile; + # message Person { + # string first_name = 1; + # string last_name = 2; + # } + # + # { + # "@type": "type.googleapis.com/google.profile.Person", + # "firstName": , + # "lastName": + # } + # + # If the embedded message type is well-known and has a custom JSON + # representation, that representation will be embedded adding a field + # `value` which holds the custom JSON in addition to the `@type` + # field. Example (for message [google.protobuf.Duration][]): + # + # { + # "@type": "type.googleapis.com/google.protobuf.Duration", + # "value": "1.212s" + # } + # @!attribute [rw] type_url + # @return [::String] + # A URL/resource name that uniquely identifies the type of the serialized + # protocol buffer message. This string must contain at least + # one "/" character. The last segment of the URL's path must represent + # the fully qualified name of the type (as in + # `path/google.protobuf.Duration`). The name should be in a canonical form + # (e.g., leading "." is not accepted). + # + # In practice, teams usually precompile into the binary all types that they + # expect it to use in the context of Any. However, for URLs which use the + # scheme `http`, `https`, or no scheme, one can optionally set up a type + # server that maps type URLs to message definitions as follows: + # + # * If no scheme is provided, `https` is assumed. + # * An HTTP GET on the URL must yield a [google.protobuf.Type][] + # value in binary format, or produce an error. + # * Applications are allowed to cache lookup results based on the + # URL, or have them precompiled into a binary to avoid any + # lookup. Therefore, binary compatibility needs to be preserved + # on changes to types. (Use versioned type names to manage + # breaking changes.) + # + # Note: this functionality is not currently available in the official + # protobuf release, and it is not used for type URLs beginning with + # type.googleapis.com. As of May 2023, there are no widely used type server + # implementations and no plans to implement one. + # + # Schemes other than `http`, `https` (or the empty scheme) might be + # used with implementation specific semantics. + # @!attribute [rw] value + # @return [::String] + # Must be a valid serialized protocol buffer of the above specified type. + class Any + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb new file mode 100644 index 000000000000..ea59f1f91daf --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb @@ -0,0 +1,98 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A Duration represents a signed, fixed-length span of time represented + # as a count of seconds and fractions of seconds at nanosecond + # resolution. It is independent of any calendar and concepts like "day" + # or "month". It is related to Timestamp in that the difference between + # two Timestamp values is a Duration and it can be added or subtracted + # from a Timestamp. Range is approximately +-10,000 years. + # + # # Examples + # + # Example 1: Compute Duration from two Timestamps in pseudo code. + # + # Timestamp start = ...; + # Timestamp end = ...; + # Duration duration = ...; + # + # duration.seconds = end.seconds - start.seconds; + # duration.nanos = end.nanos - start.nanos; + # + # if (duration.seconds < 0 && duration.nanos > 0) { + # duration.seconds += 1; + # duration.nanos -= 1000000000; + # } else if (duration.seconds > 0 && duration.nanos < 0) { + # duration.seconds -= 1; + # duration.nanos += 1000000000; + # } + # + # Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. + # + # Timestamp start = ...; + # Duration duration = ...; + # Timestamp end = ...; + # + # end.seconds = start.seconds + duration.seconds; + # end.nanos = start.nanos + duration.nanos; + # + # if (end.nanos < 0) { + # end.seconds -= 1; + # end.nanos += 1000000000; + # } else if (end.nanos >= 1000000000) { + # end.seconds += 1; + # end.nanos -= 1000000000; + # } + # + # Example 3: Compute Duration from datetime.timedelta in Python. + # + # td = datetime.timedelta(days=3, minutes=10) + # duration = Duration() + # duration.FromTimedelta(td) + # + # # JSON Mapping + # + # In JSON format, the Duration type is encoded as a string rather than an + # object, where the string ends in the suffix "s" (indicating seconds) and + # is preceded by the number of seconds, with nanoseconds expressed as + # fractional seconds. For example, 3 seconds with 0 nanoseconds should be + # encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should + # be expressed in JSON format as "3.000000001s", and 3 seconds and 1 + # microsecond should be expressed in JSON format as "3.000001s". + # @!attribute [rw] seconds + # @return [::Integer] + # Signed seconds of the span of time. Must be from -315,576,000,000 + # to +315,576,000,000 inclusive. Note: these bounds are computed from: + # 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years + # @!attribute [rw] nanos + # @return [::Integer] + # Signed fractions of a second at nanosecond resolution of the span + # of time. Durations less than one second are represented with a 0 + # `seconds` field and a positive or negative `nanos` field. For durations + # of one second or more, a non-zero value for the `nanos` field must be + # of the same sign as the `seconds` field. Must be from -999,999,999 + # to +999,999,999 inclusive. + class Duration + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb new file mode 100644 index 000000000000..83e4481834a6 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb @@ -0,0 +1,34 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A generic empty message that you can re-use to avoid defining duplicated + # empty messages in your APIs. A typical example is to use it as the request + # or the response type of an API method. For instance: + # + # service Foo { + # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); + # } + class Empty + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb new file mode 100644 index 000000000000..7f3ffc78601a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb @@ -0,0 +1,229 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # `FieldMask` represents a set of symbolic field paths, for example: + # + # paths: "f.a" + # paths: "f.b.d" + # + # Here `f` represents a field in some root message, `a` and `b` + # fields in the message found in `f`, and `d` a field found in the + # message in `f.b`. + # + # Field masks are used to specify a subset of fields that should be + # returned by a get operation or modified by an update operation. + # Field masks also have a custom JSON encoding (see below). + # + # # Field Masks in Projections + # + # When used in the context of a projection, a response message or + # sub-message is filtered by the API to only contain those fields as + # specified in the mask. For example, if the mask in the previous + # example is applied to a response message as follows: + # + # f { + # a : 22 + # b { + # d : 1 + # x : 2 + # } + # y : 13 + # } + # z: 8 + # + # The result will not contain specific values for fields x,y and z + # (their value will be set to the default, and omitted in proto text + # output): + # + # + # f { + # a : 22 + # b { + # d : 1 + # } + # } + # + # A repeated field is not allowed except at the last position of a + # paths string. + # + # If a FieldMask object is not present in a get operation, the + # operation applies to all fields (as if a FieldMask of all fields + # had been specified). + # + # Note that a field mask does not necessarily apply to the + # top-level response message. In case of a REST get operation, the + # field mask applies directly to the response, but in case of a REST + # list operation, the mask instead applies to each individual message + # in the returned resource list. In case of a REST custom method, + # other definitions may be used. Where the mask applies will be + # clearly documented together with its declaration in the API. In + # any case, the effect on the returned resource/resources is required + # behavior for APIs. + # + # # Field Masks in Update Operations + # + # A field mask in update operations specifies which fields of the + # targeted resource are going to be updated. The API is required + # to only change the values of the fields as specified in the mask + # and leave the others untouched. If a resource is passed in to + # describe the updated values, the API ignores the values of all + # fields not covered by the mask. + # + # If a repeated field is specified for an update operation, new values will + # be appended to the existing repeated field in the target resource. Note that + # a repeated field is only allowed in the last position of a `paths` string. + # + # If a sub-message is specified in the last position of the field mask for an + # update operation, then new value will be merged into the existing sub-message + # in the target resource. + # + # For example, given the target message: + # + # f { + # b { + # d: 1 + # x: 2 + # } + # c: [1] + # } + # + # And an update message: + # + # f { + # b { + # d: 10 + # } + # c: [2] + # } + # + # then if the field mask is: + # + # paths: ["f.b", "f.c"] + # + # then the result will be: + # + # f { + # b { + # d: 10 + # x: 2 + # } + # c: [1, 2] + # } + # + # An implementation may provide options to override this default behavior for + # repeated and message fields. + # + # In order to reset a field's value to the default, the field must + # be in the mask and set to the default value in the provided resource. + # Hence, in order to reset all fields of a resource, provide a default + # instance of the resource and set all fields in the mask, or do + # not provide a mask as described below. + # + # If a field mask is not present on update, the operation applies to + # all fields (as if a field mask of all fields has been specified). + # Note that in the presence of schema evolution, this may mean that + # fields the client does not know and has therefore not filled into + # the request will be reset to their default. If this is unwanted + # behavior, a specific service may require a client to always specify + # a field mask, producing an error if not. + # + # As with get operations, the location of the resource which + # describes the updated values in the request message depends on the + # operation kind. In any case, the effect of the field mask is + # required to be honored by the API. + # + # ## Considerations for HTTP REST + # + # The HTTP kind of an update operation which uses a field mask must + # be set to PATCH instead of PUT in order to satisfy HTTP semantics + # (PUT must only be used for full updates). + # + # # JSON Encoding of Field Masks + # + # In JSON, a field mask is encoded as a single string where paths are + # separated by a comma. Fields name in each path are converted + # to/from lower-camel naming conventions. + # + # As an example, consider the following message declarations: + # + # message Profile { + # User user = 1; + # Photo photo = 2; + # } + # message User { + # string display_name = 1; + # string address = 2; + # } + # + # In proto a field mask for `Profile` may look as such: + # + # mask { + # paths: "user.display_name" + # paths: "photo" + # } + # + # In JSON, the same mask is represented as below: + # + # { + # mask: "user.displayName,photo" + # } + # + # # Field Masks and Oneof Fields + # + # Field masks treat fields in oneofs just as regular fields. Consider the + # following message: + # + # message SampleMessage { + # oneof test_oneof { + # string name = 4; + # SubMessage sub_message = 9; + # } + # } + # + # The field mask can be: + # + # mask { + # paths: "name" + # } + # + # Or: + # + # mask { + # paths: "sub_message" + # } + # + # Note that oneof type names ("test_oneof" in this case) cannot be used in + # paths. + # + # ## Field Mask Verification + # + # The implementation of any API method which has a FieldMask type field in the + # request should verify the included field paths, and return an + # `INVALID_ARGUMENT` error if any path is unmappable. + # @!attribute [rw] paths + # @return [::Array<::String>] + # The set of field mask paths. + class FieldMask + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb new file mode 100644 index 000000000000..74352be9c58c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb @@ -0,0 +1,127 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A Timestamp represents a point in time independent of any time zone or local + # calendar, encoded as a count of seconds and fractions of seconds at + # nanosecond resolution. The count is relative to an epoch at UTC midnight on + # January 1, 1970, in the proleptic Gregorian calendar which extends the + # Gregorian calendar backwards to year one. + # + # All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + # second table is needed for interpretation, using a [24-hour linear + # smear](https://developers.google.com/time/smear). + # + # The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + # restricting to that range, we ensure that we can convert to and from [RFC + # 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + # + # # Examples + # + # Example 1: Compute Timestamp from POSIX `time()`. + # + # Timestamp timestamp; + # timestamp.set_seconds(time(NULL)); + # timestamp.set_nanos(0); + # + # Example 2: Compute Timestamp from POSIX `gettimeofday()`. + # + # struct timeval tv; + # gettimeofday(&tv, NULL); + # + # Timestamp timestamp; + # timestamp.set_seconds(tv.tv_sec); + # timestamp.set_nanos(tv.tv_usec * 1000); + # + # Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + # + # FILETIME ft; + # GetSystemTimeAsFileTime(&ft); + # UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + # + # // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + # // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + # Timestamp timestamp; + # timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + # timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + # + # Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + # + # long millis = System.currentTimeMillis(); + # + # Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + # .setNanos((int) ((millis % 1000) * 1000000)).build(); + # + # Example 5: Compute Timestamp from Java `Instant.now()`. + # + # Instant now = Instant.now(); + # + # Timestamp timestamp = + # Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + # .setNanos(now.getNano()).build(); + # + # Example 6: Compute Timestamp from current time in Python. + # + # timestamp = Timestamp() + # timestamp.GetCurrentTime() + # + # # JSON Mapping + # + # In JSON format, the Timestamp type is encoded as a string in the + # [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the + # format is "\\{year}-\\{month}-\\{day}T\\{hour}:\\{min}:\\{sec}[.\\{frac_sec}]Z" + # where \\{year} is always expressed using four digits while \\{month}, \\{day}, + # \\{hour}, \\{min}, and \\{sec} are zero-padded to two digits each. The fractional + # seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution), + # are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone + # is required. A proto3 JSON serializer should always use UTC (as indicated by + # "Z") when printing the Timestamp type and a proto3 JSON parser should be + # able to accept both UTC and other timezones (as indicated by an offset). + # + # For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past + # 01:30 UTC on January 15, 2017. + # + # In JavaScript, one can convert a Date object to this format using the + # standard + # [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + # method. In Python, a standard `datetime.datetime` object can be converted + # to this format using + # [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with + # the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use + # the Joda Time's [`ISODateTimeFormat.dateTime()`]( + # http://joda-time.sourceforge.net/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime() + # ) to obtain a formatter capable of generating timestamps in this format. + # @!attribute [rw] seconds + # @return [::Integer] + # Represents seconds of UTC time since Unix epoch + # 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + # 9999-12-31T23:59:59Z inclusive. + # @!attribute [rw] nanos + # @return [::Integer] + # Non-negative fractions of a second at nanosecond resolution. Negative + # second values with fractions must still have non-negative nanos values + # that count forward in time. Must be from 0 to 999,999,999 + # inclusive. + class Timestamp + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb new file mode 100644 index 000000000000..c1a1c07eb2db --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Rpc + # The `Status` type defines a logical error model that is suitable for + # different programming environments, including REST APIs and RPC APIs. It is + # used by [gRPC](https://github.com/grpc). Each `Status` message contains + # three pieces of data: error code, error message, and error details. + # + # You can find out more about this error model and how to work with it in the + # [API Design Guide](https://cloud.google.com/apis/design/errors). + # @!attribute [rw] code + # @return [::Integer] + # The status code, which should be an enum value of + # [google.rpc.Code][google.rpc.Code]. + # @!attribute [rw] message + # @return [::String] + # A developer-facing error message, which should be in English. Any + # user-facing error message should be localized and sent in the + # {::Google::Rpc::Status#details google.rpc.Status.details} field, or localized + # by the client. + # @!attribute [rw] details + # @return [::Array<::Google::Protobuf::Any>] + # A list of messages that carry the error details. There is a common set of + # message types for APIs to use. + class Status + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb new file mode 100644 index 000000000000..14ec426522d9 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb @@ -0,0 +1,53 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a whole or partial calendar date, such as a birthday. The time of + # day and time zone are either specified elsewhere or are insignificant. The + # date is relative to the Gregorian Calendar. This can represent one of the + # following: + # + # * A full date, with non-zero year, month, and day values + # * A month and day value, with a zero year, such as an anniversary + # * A year on its own, with zero month and day values + # * A year and month value, with a zero day, such as a credit card expiration + # date + # + # Related types are {::Google::Type::TimeOfDay google.type.TimeOfDay} and + # `google.protobuf.Timestamp`. + # @!attribute [rw] year + # @return [::Integer] + # Year of the date. Must be from 1 to 9999, or 0 to specify a date without + # a year. + # @!attribute [rw] month + # @return [::Integer] + # Month of a year. Must be from 1 to 12, or 0 to specify a year without a + # month and day. + # @!attribute [rw] day + # @return [::Integer] + # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 + # to specify a year by itself or a year and month where the day isn't + # significant. + class Date + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb new file mode 100644 index 000000000000..d15ba7af54e4 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb @@ -0,0 +1,103 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents civil time (or occasionally physical time). + # + # This type can represent a civil time in one of a few possible ways: + # + # * When utc_offset is set and time_zone is unset: a civil time on a calendar + # day with a particular offset from UTC. + # * When time_zone is set and utc_offset is unset: a civil time on a calendar + # day in a particular time zone. + # * When neither time_zone nor utc_offset is set: a civil time on a calendar + # day in local time. + # + # The date is relative to the Proleptic Gregorian Calendar. + # + # If year is 0, the DateTime is considered not to have a specific year. month + # and day must have valid, non-zero values. + # + # This type may also be used to represent a physical time if all the date and + # time fields are set and either case of the `time_offset` oneof is set. + # Consider using `Timestamp` message for physical time instead. If your use + # case also would like to store the user's timezone, that can be done in + # another field. + # + # This type is more flexible than some applications may want. Make sure to + # document and validate your application's limitations. + # @!attribute [rw] year + # @return [::Integer] + # Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a + # datetime without a year. + # @!attribute [rw] month + # @return [::Integer] + # Required. Month of year. Must be from 1 to 12. + # @!attribute [rw] day + # @return [::Integer] + # Required. Day of month. Must be from 1 to 31 and valid for the year and + # month. + # @!attribute [rw] hours + # @return [::Integer] + # Required. Hours of day in 24 hour format. Should be from 0 to 23. An API + # may choose to allow the value "24:00:00" for scenarios like business + # closing time. + # @!attribute [rw] minutes + # @return [::Integer] + # Required. Minutes of hour of day. Must be from 0 to 59. + # @!attribute [rw] seconds + # @return [::Integer] + # Required. Seconds of minutes of the time. Must normally be from 0 to 59. An + # API may allow the value 60 if it allows leap-seconds. + # @!attribute [rw] nanos + # @return [::Integer] + # Required. Fractions of seconds in nanoseconds. Must be from 0 to + # 999,999,999. + # @!attribute [rw] utc_offset + # @return [::Google::Protobuf::Duration] + # UTC offset. Must be whole seconds, between -18 hours and +18 hours. + # For example, a UTC offset of -4:00 would be represented as + # { seconds: -14400 }. + # + # Note: The following fields are mutually exclusive: `utc_offset`, `time_zone`. If a field in that set is populated, all other fields in the set will automatically be cleared. + # @!attribute [rw] time_zone + # @return [::Google::Type::TimeZone] + # Time zone. + # + # Note: The following fields are mutually exclusive: `time_zone`, `utc_offset`. If a field in that set is populated, all other fields in the set will automatically be cleared. + class DateTime + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents a time zone from the + # [IANA Time Zone Database](https://www.iana.org/time-zones). + # @!attribute [rw] id + # @return [::String] + # IANA Time Zone Database time zone, e.g. "America/New_York". + # @!attribute [rw] version + # @return [::String] + # Optional. IANA Time Zone Database version number, e.g. "2019a". + class TimeZone + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb new file mode 100644 index 000000000000..973211b9ffe7 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb @@ -0,0 +1,49 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a day of the week. + module DayOfWeek + # The day of the week is unspecified. + DAY_OF_WEEK_UNSPECIFIED = 0 + + # Monday + MONDAY = 1 + + # Tuesday + TUESDAY = 2 + + # Wednesday + WEDNESDAY = 3 + + # Thursday + THURSDAY = 4 + + # Friday + FRIDAY = 5 + + # Saturday + SATURDAY = 6 + + # Sunday + SUNDAY = 7 + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb new file mode 100644 index 000000000000..9cd0c16495dd --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb @@ -0,0 +1,135 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a postal address, e.g. for postal delivery or payments addresses. + # Given a postal address, a postal service can deliver items to a premise, P.O. + # Box or similar. + # It is not intended to model geographical locations (roads, towns, + # mountains). + # + # In typical usage an address would be created via user input or from importing + # existing data, depending on the type of process. + # + # Advice on address input / editing: + # - Use an i18n-ready address widget such as + # https://github.com/google/libaddressinput) + # - Users should not be presented with UI elements for input or editing of + # fields outside countries where that field is used. + # + # For more guidance on how to use this schema, please see: + # https://support.google.com/business/answer/6397478 + # @!attribute [rw] revision + # @return [::Integer] + # The schema revision of the `PostalAddress`. This must be set to 0, which is + # the latest revision. + # + # All new revisions **must** be backward compatible with old revisions. + # @!attribute [rw] region_code + # @return [::String] + # Required. CLDR region code of the country/region of the address. This + # is never inferred and it is up to the user to ensure the value is + # correct. See http://cldr.unicode.org/ and + # http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html + # for details. Example: "CH" for Switzerland. + # @!attribute [rw] language_code + # @return [::String] + # Optional. BCP-47 language code of the contents of this address (if + # known). This is often the UI language of the input form or is expected + # to match one of the languages used in the address' country/region, or their + # transliterated equivalents. + # This can affect formatting in certain countries, but is not critical + # to the correctness of the data and will never affect any validation or + # other non-formatting related operations. + # + # If this value is not known, it should be omitted (rather than specifying a + # possibly incorrect default). + # + # Examples: "zh-Hant", "ja", "ja-Latn", "en". + # @!attribute [rw] postal_code + # @return [::String] + # Optional. Postal code of the address. Not all countries use or require + # postal codes to be present, but where they are used, they may trigger + # additional validation with other parts of the address (e.g. state/zip + # validation in the U.S.A.). + # @!attribute [rw] sorting_code + # @return [::String] + # Optional. Additional, country-specific, sorting code. This is not used + # in most regions. Where it is used, the value is either a string like + # "CEDEX", optionally followed by a number (e.g. "CEDEX 7"), or just a number + # alone, representing the "sector code" (Jamaica), "delivery area indicator" + # (Malawi) or "post office indicator" (e.g. Côte d'Ivoire). + # @!attribute [rw] administrative_area + # @return [::String] + # Optional. Highest administrative subdivision which is used for postal + # addresses of a country or region. + # For example, this can be a state, a province, an oblast, or a prefecture. + # Specifically, for Spain this is the province and not the autonomous + # community (e.g. "Barcelona" and not "Catalonia"). + # Many countries don't use an administrative area in postal addresses. E.g. + # in Switzerland this should be left unpopulated. + # @!attribute [rw] locality + # @return [::String] + # Optional. Generally refers to the city/town portion of the address. + # Examples: US city, IT comune, UK post town. + # In regions of the world where localities are not well defined or do not fit + # into this structure well, leave locality empty and use address_lines. + # @!attribute [rw] sublocality + # @return [::String] + # Optional. Sublocality of the address. + # For example, this can be neighborhoods, boroughs, districts. + # @!attribute [rw] address_lines + # @return [::Array<::String>] + # Unstructured address lines describing the lower levels of an address. + # + # Because values in address_lines do not have type information and may + # sometimes contain multiple values in a single field (e.g. + # "Austin, TX"), it is important that the line order is clear. The order of + # address lines should be "envelope order" for the country/region of the + # address. In places where this can vary (e.g. Japan), address_language is + # used to make it explicit (e.g. "ja" for large-to-small ordering and + # "ja-Latn" or "en" for small-to-large). This way, the most specific line of + # an address can be selected based on the language. + # + # The minimum permitted structural representation of an address consists + # of a region_code with all remaining information placed in the + # address_lines. It would be possible to format such an address very + # approximately without geocoding, but no semantic reasoning could be + # made about any of the address components until it was at least + # partially resolved. + # + # Creating an address only containing a region_code and address_lines, and + # then geocoding is the recommended way to handle completely unstructured + # addresses (as opposed to guessing which parts of the address should be + # localities or administrative areas). + # @!attribute [rw] recipients + # @return [::Array<::String>] + # Optional. The recipient at the address. + # This field may, under certain circumstances, contain multiline information. + # For example, it might contain "care of" information. + # @!attribute [rw] organization + # @return [::String] + # Optional. The name of the organization at the address. + class PostalAddress + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb new file mode 100644 index 000000000000..b0c888c8c14a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a time of day. The date and time zone are either not significant + # or are specified elsewhere. An API may choose to allow leap seconds. Related + # types are {::Google::Type::Date google.type.Date} and + # `google.protobuf.Timestamp`. + # @!attribute [rw] hours + # @return [::Integer] + # Hours of day in 24 hour format. Should be from 0 to 23. An API may choose + # to allow the value "24:00:00" for scenarios like business closing time. + # @!attribute [rw] minutes + # @return [::Integer] + # Minutes of hour of day. Must be from 0 to 59. + # @!attribute [rw] seconds + # @return [::Integer] + # Seconds of minutes of the time. Must normally be from 0 to 59. An API may + # allow the value 60 if it allows leap-seconds. + # @!attribute [rw] nanos + # @return [::Integer] + # Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999. + class TimeOfDay + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile new file mode 100644 index 000000000000..bc4dfa6ce8bb --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile @@ -0,0 +1,32 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +source "https://rubygems.org" + +if ENV["GOOGLE_CLOUD_SAMPLES_TEST"] == "master" + gem "google-cloud-gdc_hardware_management-v1alpha", path: "../" +else + gem "google-cloud-gdc_hardware_management-v1alpha" +end + +group :test do + gem "google-style", "~> 1.26.1" + gem "minitest", "~> 5.16" + gem "minitest-focus", "~> 1.1" + gem "minitest-hooks", "~> 1.5" +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb new file mode 100644 index 000000000000..e5bd5c423c3b --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the cancel_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order. +# +def cancel_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new + + # Call the cancel_order method. + result = client.cancel_order request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb new file mode 100644 index 000000000000..062eb7e3ef99 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_comment call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment. +# +def create_comment + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new + + # Call the create_comment method. + result = client.create_comment request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb new file mode 100644 index 000000000000..c32bad4e6a94 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_hardware call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware. +# +def create_hardware + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new + + # Call the create_hardware method. + result = client.create_hardware request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb new file mode 100644 index 000000000000..50d51125fa19 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_hardware_group call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group. +# +def create_hardware_group + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new + + # Call the create_hardware_group method. + result = client.create_hardware_group request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb new file mode 100644 index 000000000000..8c945f8aa66e --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order. +# +def create_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new + + # Call the create_order method. + result = client.create_order request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb new file mode 100644 index 000000000000..7e1b922105b5 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_site call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site. +# +def create_site + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new + + # Call the create_site method. + result = client.create_site request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb new file mode 100644 index 000000000000..4651805796c6 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the create_zone call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone. +# +def create_zone + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new + + # Call the create_zone method. + result = client.create_zone request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb new file mode 100644 index 000000000000..e26abc148d39 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the delete_hardware call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware. +# +def delete_hardware + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new + + # Call the delete_hardware method. + result = client.delete_hardware request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb new file mode 100644 index 000000000000..57375279b7b7 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the delete_hardware_group call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group. +# +def delete_hardware_group + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new + + # Call the delete_hardware_group method. + result = client.delete_hardware_group request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb new file mode 100644 index 000000000000..2e6a508f59c6 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the delete_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order. +# +def delete_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new + + # Call the delete_order method. + result = client.delete_order request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb new file mode 100644 index 000000000000..1f66ee279ec0 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the delete_site call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site. +# +def delete_site + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new + + # Call the delete_site method. + result = client.delete_site request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb new file mode 100644 index 000000000000..6928b1a8ce3f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the delete_zone call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone. +# +def delete_zone + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new + + # Call the delete_zone method. + result = client.delete_zone request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb new file mode 100644 index 000000000000..79c9468fa048 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_change_log_entry call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry. +# +def get_change_log_entry + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new + + # Call the get_change_log_entry method. + result = client.get_change_log_entry request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb new file mode 100644 index 000000000000..daf60605d6ad --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_comment call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment. +# +def get_comment + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new + + # Call the get_comment method. + result = client.get_comment request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb new file mode 100644 index 000000000000..6a4cdf59e3dc --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_hardware call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware. +# +def get_hardware + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new + + # Call the get_hardware method. + result = client.get_hardware request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb new file mode 100644 index 000000000000..029aa4e5843f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_hardware_group call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group. +# +def get_hardware_group + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new + + # Call the get_hardware_group method. + result = client.get_hardware_group request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb new file mode 100644 index 000000000000..57af00353628 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order. +# +def get_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new + + # Call the get_order method. + result = client.get_order request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb new file mode 100644 index 000000000000..26c42c9b8c06 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_site call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site. +# +def get_site + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new + + # Call the get_site method. + result = client.get_site request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb new file mode 100644 index 000000000000..cbf346bbb908 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_sku call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku. +# +def get_sku + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new + + # Call the get_sku method. + result = client.get_sku request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb new file mode 100644 index 000000000000..7f966c999986 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the get_zone call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone. +# +def get_zone + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new + + # Call the get_zone method. + result = client.get_zone request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb new file mode 100644 index 000000000000..233c809f62cb --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_change_log_entries call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries. +# +def list_change_log_entries + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new + + # Call the list_change_log_entries method. + result = client.list_change_log_entries request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb new file mode 100644 index 000000000000..d262606f7295 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_comments call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments. +# +def list_comments + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new + + # Call the list_comments method. + result = client.list_comments request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb new file mode 100644 index 000000000000..43d212bbdabf --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_hardware call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware. +# +def list_hardware + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new + + # Call the list_hardware method. + result = client.list_hardware request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb new file mode 100644 index 000000000000..ff05fedcd54c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_hardware_groups call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups. +# +def list_hardware_groups + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new + + # Call the list_hardware_groups method. + result = client.list_hardware_groups request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb new file mode 100644 index 000000000000..93864a8f35f2 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_orders call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders. +# +def list_orders + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new + + # Call the list_orders method. + result = client.list_orders request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb new file mode 100644 index 000000000000..b60a042059fb --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_sites call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites. +# +def list_sites + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new + + # Call the list_sites method. + result = client.list_sites request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb new file mode 100644 index 000000000000..909dbe2038eb --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_skus call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus. +# +def list_skus + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new + + # Call the list_skus method. + result = client.list_skus request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb new file mode 100644 index 000000000000..bea66ba9bc2f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the list_zones call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones. +# +def list_zones + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new + + # Call the list_zones method. + result = client.list_zones request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. + p item + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb new file mode 100644 index 000000000000..5a00e3446e6a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the record_action_on_comment call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment. +# +def record_action_on_comment + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new + + # Call the record_action_on_comment method. + result = client.record_action_on_comment request + + # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. + p result +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb new file mode 100644 index 000000000000..723bf8387b20 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the request_order_date_change call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change. +# +def request_order_date_change + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new + + # Call the request_order_date_change method. + result = client.request_order_date_change request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb new file mode 100644 index 000000000000..70f0d340ff17 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the signal_zone_state call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state. +# +def signal_zone_state + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new + + # Call the signal_zone_state method. + result = client.signal_zone_state request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb new file mode 100644 index 000000000000..93d353c3f9bd --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the submit_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order. +# +def submit_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new + + # Call the submit_order method. + result = client.submit_order request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb new file mode 100644 index 000000000000..c40036ffab3c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the update_hardware call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware. +# +def update_hardware + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new + + # Call the update_hardware method. + result = client.update_hardware request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb new file mode 100644 index 000000000000..2b813dfc0196 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the update_hardware_group call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group. +# +def update_hardware_group + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new + + # Call the update_hardware_group method. + result = client.update_hardware_group request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb new file mode 100644 index 000000000000..75de15ad44ff --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the update_order call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order. +# +def update_order + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new + + # Call the update_order method. + result = client.update_order request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb new file mode 100644 index 000000000000..afa54b028217 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the update_site call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site. +# +def update_site + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new + + # Call the update_site method. + result = client.update_site request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb new file mode 100644 index 000000000000..fd3682f19c7c --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync] +require "google/cloud/gdc_hardware_management/v1alpha" + +## +# Snippet for the update_zone call in the GDCHardwareManagement service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone. +# +def update_zone + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new + + # Call the update_zone method. + result = client.update_zone request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json new file mode 100644 index 000000000000..bec0bf6c87e3 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json @@ -0,0 +1,1495 @@ +{ + "client_library": { + "name": "google-cloud-gdc_hardware_management-v1alpha", + "version": "", + "language": "RUBY", + "apis": [ + { + "id": "google.cloud.gdchardwaremanagement.v1alpha", + "version": "v1alpha" + } + ] + }, + "snippets": [ + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync", + "title": "Snippet for the list_orders call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders.", + "file": "gdc_hardware_management/list_orders.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_orders", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListOrders", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListOrders", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync", + "title": "Snippet for the get_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order.", + "file": "gdc_hardware_management/get_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Order", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync", + "title": "Snippet for the create_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order.", + "file": "gdc_hardware_management/create_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync", + "title": "Snippet for the update_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order.", + "file": "gdc_hardware_management/update_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "update_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "UpdateOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync", + "title": "Snippet for the delete_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order.", + "file": "gdc_hardware_management/delete_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "DeleteOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync", + "title": "Snippet for the submit_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order.", + "file": "gdc_hardware_management/submit_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "submit_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "SubmitOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.SubmitOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync", + "title": "Snippet for the cancel_order call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order.", + "file": "gdc_hardware_management/cancel_order.rb", + "language": "RUBY", + "client_method": { + "short_name": "cancel_order", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CancelOrder", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CancelOrder", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync", + "title": "Snippet for the list_sites call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites.", + "file": "gdc_hardware_management/list_sites.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_sites", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListSites", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListSites", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync", + "title": "Snippet for the get_site call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site.", + "file": "gdc_hardware_management/get_site.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_site", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Site", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetSite", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetSite", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync", + "title": "Snippet for the create_site call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site.", + "file": "gdc_hardware_management/create_site.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_site", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateSite", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateSite", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync", + "title": "Snippet for the update_site call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site.", + "file": "gdc_hardware_management/update_site.rb", + "language": "RUBY", + "client_method": { + "short_name": "update_site", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "UpdateSite", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateSite", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync", + "title": "Snippet for the delete_site call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site.", + "file": "gdc_hardware_management/delete_site.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_site", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "DeleteSite", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteSite", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync", + "title": "Snippet for the list_hardware_groups call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups.", + "file": "gdc_hardware_management/list_hardware_groups.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_hardware_groups", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListHardwareGroups", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListHardwareGroups", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync", + "title": "Snippet for the get_hardware_group call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group.", + "file": "gdc_hardware_management/get_hardware_group.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_hardware_group", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetHardwareGroup", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetHardwareGroup", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync", + "title": "Snippet for the create_hardware_group call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group.", + "file": "gdc_hardware_management/create_hardware_group.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_hardware_group", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateHardwareGroup", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateHardwareGroup", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync", + "title": "Snippet for the update_hardware_group call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group.", + "file": "gdc_hardware_management/update_hardware_group.rb", + "language": "RUBY", + "client_method": { + "short_name": "update_hardware_group", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "UpdateHardwareGroup", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateHardwareGroup", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync", + "title": "Snippet for the delete_hardware_group call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group.", + "file": "gdc_hardware_management/delete_hardware_group.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_hardware_group", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "DeleteHardwareGroup", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteHardwareGroup", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync", + "title": "Snippet for the list_hardware call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware.", + "file": "gdc_hardware_management/list_hardware.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_hardware", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListHardware", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListHardware", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync", + "title": "Snippet for the get_hardware call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware.", + "file": "gdc_hardware_management/get_hardware.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_hardware", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetHardware", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetHardware", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync", + "title": "Snippet for the create_hardware call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware.", + "file": "gdc_hardware_management/create_hardware.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_hardware", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateHardware", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateHardware", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync", + "title": "Snippet for the update_hardware call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware.", + "file": "gdc_hardware_management/update_hardware.rb", + "language": "RUBY", + "client_method": { + "short_name": "update_hardware", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "UpdateHardware", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateHardware", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync", + "title": "Snippet for the delete_hardware call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware.", + "file": "gdc_hardware_management/delete_hardware.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_hardware", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "DeleteHardware", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteHardware", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync", + "title": "Snippet for the list_comments call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments.", + "file": "gdc_hardware_management/list_comments.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_comments", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListComments", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListComments", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync", + "title": "Snippet for the get_comment call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment.", + "file": "gdc_hardware_management/get_comment.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_comment", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Comment", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetComment", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetComment", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync", + "title": "Snippet for the create_comment call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment.", + "file": "gdc_hardware_management/create_comment.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_comment", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateComment", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateComment", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync", + "title": "Snippet for the record_action_on_comment call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment.", + "file": "gdc_hardware_management/record_action_on_comment.rb", + "language": "RUBY", + "client_method": { + "short_name": "record_action_on_comment", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Comment", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "RecordActionOnComment", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.RecordActionOnComment", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync", + "title": "Snippet for the list_change_log_entries call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries.", + "file": "gdc_hardware_management/list_change_log_entries.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_change_log_entries", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListChangeLogEntries", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListChangeLogEntries", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync", + "title": "Snippet for the get_change_log_entry call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry.", + "file": "gdc_hardware_management/get_change_log_entry.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_change_log_entry", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetChangeLogEntry", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetChangeLogEntry", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync", + "title": "Snippet for the list_skus call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus.", + "file": "gdc_hardware_management/list_skus.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_skus", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListSkus", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListSkus", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync", + "title": "Snippet for the get_sku call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku.", + "file": "gdc_hardware_management/get_sku.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_sku", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Sku", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetSku", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetSku", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync", + "title": "Snippet for the list_zones call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones.", + "file": "gdc_hardware_management/list_zones.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_zones", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "ListZones", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListZones", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync", + "title": "Snippet for the get_zone call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone.", + "file": "gdc_hardware_management/get_zone.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_zone", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Zone", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "GetZone", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetZone", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync", + "title": "Snippet for the create_zone call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone.", + "file": "gdc_hardware_management/create_zone.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_zone", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "CreateZone", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateZone", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync", + "title": "Snippet for the update_zone call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone.", + "file": "gdc_hardware_management/update_zone.rb", + "language": "RUBY", + "client_method": { + "short_name": "update_zone", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "UpdateZone", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateZone", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync", + "title": "Snippet for the delete_zone call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone.", + "file": "gdc_hardware_management/delete_zone.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_zone", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "DeleteZone", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteZone", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync", + "title": "Snippet for the signal_zone_state call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state.", + "file": "gdc_hardware_management/signal_zone_state.rb", + "language": "RUBY", + "client_method": { + "short_name": "signal_zone_state", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "SignalZoneState", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.SignalZoneState", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync", + "title": "Snippet for the request_order_date_change call in the GDCHardwareManagement service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change.", + "file": "gdc_hardware_management/request_order_date_change.rb", + "language": "RUBY", + "client_method": { + "short_name": "request_order_date_change", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "GDCHardwareManagement::Client", + "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" + }, + "method": { + "short_name": "RequestOrderDateChange", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.RequestOrderDateChange", + "service": { + "short_name": "GDCHardwareManagement", + "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + } + ] +} \ No newline at end of file diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb new file mode 100644 index 000000000000..84f131151d1f --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb @@ -0,0 +1,400 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "helper" + +require "gapic/grpc/service_stub" + +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" +require "google/cloud/gdchardwaremanagement/v1alpha/service_services_pb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" + +class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::OperationsTest < Minitest::Test + class ClientStub + attr_accessor :call_rpc_count, :requests + + def initialize response, operation, &block + @response = response + @operation = operation + @block = block + @call_rpc_count = 0 + @requests = [] + end + + def call_rpc *args, **kwargs + @call_rpc_count += 1 + + @requests << @block&.call(*args, **kwargs) + + catch :response do + yield @response, @operation if block_given? + @response + end + end + + def endpoint + "endpoint.example.com" + end + + def universe_domain + "example.com" + end + + def stub_logger + nil + end + + def logger + nil + end + end + + def test_list_operations + # Create GRPC objects. + grpc_response = ::Google::Longrunning::ListOperationsResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + filter = "hello world" + page_size = 42 + page_token = "hello world" + return_partial_success = true + + list_operations_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_operations, name + assert_kind_of ::Google::Longrunning::ListOperationsRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["filter"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal true, request["return_partial_success"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_operations_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_operations({ name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_operations name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_operations ::Google::Longrunning::ListOperationsRequest.new(name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_operations({ name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_operations(::Google::Longrunning::ListOperationsRequest.new(name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_operations_client_stub.call_rpc_count + end + end + + def test_get_operation + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_operation, name + assert_kind_of ::Google::Longrunning::GetOperationRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_operation_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_operation({ name: name }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_operation name: name do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_operation ::Google::Longrunning::GetOperationRequest.new(name: name) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_operation({ name: name }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_operation(::Google::Longrunning::GetOperationRequest.new(name: name), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_operation_client_stub.call_rpc_count + end + end + + def test_delete_operation + # Create GRPC objects. + grpc_response = ::Google::Protobuf::Empty.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + delete_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_operation, name + assert_kind_of ::Google::Longrunning::DeleteOperationRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_operation_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_operation({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_operation name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_operation ::Google::Longrunning::DeleteOperationRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_operation({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_operation(::Google::Longrunning::DeleteOperationRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_operation_client_stub.call_rpc_count + end + end + + def test_cancel_operation + # Create GRPC objects. + grpc_response = ::Google::Protobuf::Empty.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + cancel_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :cancel_operation, name + assert_kind_of ::Google::Longrunning::CancelOperationRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, cancel_operation_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.cancel_operation({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.cancel_operation name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.cancel_operation ::Google::Longrunning::CancelOperationRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.cancel_operation({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.cancel_operation(::Google::Longrunning::CancelOperationRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, cancel_operation_client_stub.call_rpc_count + end + end + + def test_wait_operation + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + timeout = {} + + wait_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :wait_operation, name + assert_kind_of ::Google::Longrunning::WaitOperationRequest, request + assert_equal "hello world", request["name"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::Duration), request["timeout"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, wait_operation_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.wait_operation({ name: name, timeout: timeout }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.wait_operation name: name, timeout: timeout do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.wait_operation ::Google::Longrunning::WaitOperationRequest.new(name: name, timeout: timeout) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.wait_operation({ name: name, timeout: timeout }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.wait_operation(::Google::Longrunning::WaitOperationRequest.new(name: name, timeout: timeout), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, wait_operation_client_stub.call_rpc_count + end + end + + def test_configure + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + + client = block_config = config = nil + dummy_stub = ClientStub.new nil, nil + Gapic::ServiceStub.stub :new, dummy_stub do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| + config.credentials = grpc_channel + end + end + + config = client.configure do |c| + block_config = c + end + + assert_same block_config, config + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations::Configuration, config + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb new file mode 100644 index 000000000000..b4561b9b4999 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb @@ -0,0 +1,151 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "helper" + +require "gapic/grpc/service_stub" + +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" + +class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::ClientPathsTest < Minitest::Test + class DummyStub + def endpoint + "endpoint.example.com" + end + + def universe_domain + "example.com" + end + + def stub_logger + nil + end + + def logger + nil + end + end + + def test_change_log_entry_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.change_log_entry_path project: "value0", location: "value1", order: "value2", change_log_entry: "value3" + assert_equal "projects/value0/locations/value1/orders/value2/changeLogEntries/value3", path + end + end + + def test_comment_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.comment_path project: "value0", location: "value1", order: "value2", comment: "value3" + assert_equal "projects/value0/locations/value1/orders/value2/comments/value3", path + end + end + + def test_hardware_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.hardware_path project: "value0", location: "value1", hardware: "value2" + assert_equal "projects/value0/locations/value1/hardware/value2", path + end + end + + def test_hardware_group_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.hardware_group_path project: "value0", location: "value1", order: "value2", hardware_group: "value3" + assert_equal "projects/value0/locations/value1/orders/value2/hardwareGroups/value3", path + end + end + + def test_location_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.location_path project: "value0", location: "value1" + assert_equal "projects/value0/locations/value1", path + end + end + + def test_order_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.order_path project: "value0", location: "value1", order: "value2" + assert_equal "projects/value0/locations/value1/orders/value2", path + end + end + + def test_site_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.site_path project: "value0", location: "value1", site: "value2" + assert_equal "projects/value0/locations/value1/sites/value2", path + end + end + + def test_sku_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.sku_path project: "value0", location: "value1", sku: "value2" + assert_equal "projects/value0/locations/value1/skus/value2", path + end + end + + def test_zone_path + grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + ::Gapic::ServiceStub.stub :new, DummyStub.new do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + path = client.zone_path project: "value0", location: "value1", zone: "value2" + assert_equal "projects/value0/locations/value1/zones/value2", path + end + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb new file mode 100644 index 000000000000..2af55a6e9488 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb @@ -0,0 +1,2172 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "helper" +require "gapic/rest" +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" + + +class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ClientTest < Minitest::Test + class ClientStub + attr_accessor :call_count, :requests + + def initialize response, &block + @response = response + @block = block + @call_count = 0 + @requests = [] + end + + def make_get_request uri:, params: {}, options: {}, method_name: nil + make_http_request :get, uri: uri, body: nil, params: params, options: options, method_name: method_name + end + + def make_delete_request uri:, params: {}, options: {}, method_name: nil + make_http_request :delete, uri: uri, body: nil, params: params, options: options, method_name: method_name + end + + def make_post_request uri:, body: nil, params: {}, options: {}, method_name: nil + make_http_request :post, uri: uri, body: body, params: params, options: options, method_name: method_name + end + + def make_patch_request uri:, body:, params: {}, options: {}, method_name: nil + make_http_request :patch, uri: uri, body: body, params: params, options: options, method_name: method_name + end + + def make_put_request uri:, body:, params: {}, options: {}, method_name: nil + make_http_request :put, uri: uri, body: body, params: params, options: options, method_name: method_name + end + + def make_http_request *args, **kwargs + @call_count += 1 + + @requests << @block&.call(*args, **kwargs) + + @response + end + + def endpoint + "endpoint.example.com" + end + + def universe_domain + "example.com" + end + + def stub_logger + nil + end + + def logger + nil + end + end + + def test_list_orders + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_orders_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_orders_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_orders_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_orders parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_orders ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_orders(::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_orders_client_stub.call_count + end + end + end + + def test_get_order + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_order({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_order name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_order ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_order({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_order(::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_order_client_stub.call_count + end + end + end + + def test_create_order + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + order_id = "hello world" + order = {} + request_id = "hello world" + + create_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_order parent: parent, order_id: order_id, order: order, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_order_client_stub.call_count + end + end + end + + def test_update_order + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + update_mask = {} + order = {} + request_id = "hello world" + + update_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, update_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.update_order({ update_mask: update_mask, order: order, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.update_order update_mask: update_mask, order: order, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.update_order ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.update_order({ update_mask: update_mask, order: order, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.update_order(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, update_order_client_stub.call_count + end + end + end + + def test_delete_order + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + force = true + + delete_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_order({ name: name, request_id: request_id, force: force }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_order name: name, request_id: request_id, force: force do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_order ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_order({ name: name, request_id: request_id, force: force }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_order(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_order_client_stub.call_count + end + end + end + + def test_submit_order + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + type = :TYPE_UNSPECIFIED + + submit_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_submit_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, submit_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.submit_order({ name: name, request_id: request_id, type: type }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.submit_order name: name, request_id: request_id, type: type do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.submit_order ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.submit_order({ name: name, request_id: request_id, type: type }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.submit_order(::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, submit_order_client_stub.call_count + end + end + end + + def test_cancel_order + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + cancel_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_cancel_order_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, cancel_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.cancel_order({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.cancel_order name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.cancel_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.cancel_order({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.cancel_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, cancel_order_client_stub.call_count + end + end + end + + def test_list_sites + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_sites_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_sites_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_sites_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_sites parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_sites ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_sites(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_sites_client_stub.call_count + end + end + end + + def test_get_site + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_site_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_site({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_site name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_site ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_site({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_site(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_site_client_stub.call_count + end + end + end + + def test_create_site + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + site_id = "hello world" + site = {} + request_id = "hello world" + + create_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_site_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_site parent: parent, site_id: site_id, site: site, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_site ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_site(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_site_client_stub.call_count + end + end + end + + def test_update_site + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + update_mask = {} + site = {} + request_id = "hello world" + + update_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_site_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, update_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.update_site({ update_mask: update_mask, site: site, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.update_site update_mask: update_mask, site: site, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.update_site ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.update_site({ update_mask: update_mask, site: site, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.update_site(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, update_site_client_stub.call_count + end + end + end + + def test_delete_site + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_site_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_site({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_site name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_site ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_site({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_site(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_site_client_stub.call_count + end + end + end + + def test_list_hardware_groups + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_hardware_groups_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_hardware_groups_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_hardware_groups_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_hardware_groups parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_hardware_groups ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_hardware_groups(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_hardware_groups_client_stub.call_count + end + end + end + + def test_get_hardware_group + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_hardware_group_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_hardware_group({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_hardware_group name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_hardware_group({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_hardware_group_client_stub.call_count + end + end + end + + def test_create_hardware_group + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + hardware_group_id = "hello world" + hardware_group = {} + request_id = "hello world" + + create_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_hardware_group_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_hardware_group parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_hardware_group_client_stub.call_count + end + end + end + + def test_update_hardware_group + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + update_mask = {} + hardware_group = {} + request_id = "hello world" + + update_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_hardware_group_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, update_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.update_hardware_group update_mask: update_mask, hardware_group: hardware_group, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.update_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.update_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, update_hardware_group_client_stub.call_count + end + end + end + + def test_delete_hardware_group + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_hardware_group_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_hardware_group({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_hardware_group name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_hardware_group({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_hardware_group_client_stub.call_count + end + end + end + + def test_list_hardware + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_hardware_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_hardware parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_hardware_client_stub.call_count + end + end + end + + def test_get_hardware + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_hardware_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_hardware({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_hardware name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_hardware({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_hardware_client_stub.call_count + end + end + end + + def test_create_hardware + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + hardware_id = "hello world" + hardware = {} + + create_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_hardware_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_hardware parent: parent, hardware_id: hardware_id, hardware: hardware do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_hardware_client_stub.call_count + end + end + end + + def test_update_hardware + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + update_mask = {} + hardware = {} + request_id = "hello world" + + update_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_hardware_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, update_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.update_hardware update_mask: update_mask, hardware: hardware, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.update_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.update_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, update_hardware_client_stub.call_count + end + end + end + + def test_delete_hardware + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_hardware_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_hardware({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_hardware name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_hardware({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_hardware_client_stub.call_count + end + end + end + + def test_list_comments + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_comments_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_comments_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_comments_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_comments parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_comments ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_comments(::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_comments_client_stub.call_count + end + end + end + + def test_get_comment + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_comment_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_comment({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_comment name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_comment({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_comment_client_stub.call_count + end + end + end + + def test_create_comment + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + comment_id = "hello world" + comment = {} + request_id = "hello world" + + create_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_comment_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_comment parent: parent, comment_id: comment_id, comment: comment, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_comment_client_stub.call_count + end + end + end + + def test_record_action_on_comment + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + action_type = :ACTION_TYPE_UNSPECIFIED + + record_action_on_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_record_action_on_comment_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, record_action_on_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.record_action_on_comment({ name: name, action_type: action_type }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.record_action_on_comment name: name, action_type: action_type do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.record_action_on_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.record_action_on_comment({ name: name, action_type: action_type }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.record_action_on_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, record_action_on_comment_client_stub.call_count + end + end + end + + def test_list_change_log_entries + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_change_log_entries_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_change_log_entries_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_change_log_entries_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_change_log_entries parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_change_log_entries ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_change_log_entries(::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_change_log_entries_client_stub.call_count + end + end + end + + def test_get_change_log_entry + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_change_log_entry_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_change_log_entry_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_change_log_entry_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_change_log_entry({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_change_log_entry name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_change_log_entry ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_change_log_entry({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_change_log_entry(::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_change_log_entry_client_stub.call_count + end + end + end + + def test_list_skus + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_skus_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_skus_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_skus_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_skus parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_skus ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_skus(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_skus_client_stub.call_count + end + end + end + + def test_get_sku + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_sku_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_sku_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_sku_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_sku({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_sku name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_sku ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_sku({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_sku(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_sku_client_stub.call_count + end + end + end + + def test_list_zones + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_zones_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_zones_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_zones_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_zones parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_zones ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_zones(::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_zones_client_stub.call_count + end + end + end + + def test_get_zone + # Create test objects. + client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_zone_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_zone({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_zone name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_zone({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_zone_client_stub.call_count + end + end + end + + def test_create_zone + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + zone_id = "hello world" + zone = {} + request_id = "hello world" + + create_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_zone_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_zone parent: parent, zone_id: zone_id, zone: zone, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_zone_client_stub.call_count + end + end + end + + def test_update_zone + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + update_mask = {} + zone = {} + request_id = "hello world" + + update_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_zone_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, update_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.update_zone update_mask: update_mask, zone: zone, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.update_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.update_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, update_zone_client_stub.call_count + end + end + end + + def test_delete_zone + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_zone_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_zone({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_zone name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_zone({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_zone_client_stub.call_count + end + end + end + + def test_signal_zone_state + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + state_signal = :STATE_SIGNAL_UNSPECIFIED + provisioning_state_signal = :PROVISIONING_STATE_SIGNAL_UNSPECIFIED + step = "hello world" + details = "hello world" + + signal_zone_state_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_signal_zone_state_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, signal_zone_state_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.signal_zone_state name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.signal_zone_state ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.signal_zone_state(::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, signal_zone_state_client_stub.call_count + end + end + end + + def test_request_order_date_change + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + requested_date = {} + + request_order_date_change_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_request_order_date_change_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, request_order_date_change_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.request_order_date_change({ name: name, requested_date: requested_date }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.request_order_date_change name: name, requested_date: requested_date do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.request_order_date_change ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.request_order_date_change({ name: name, requested_date: requested_date }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.request_order_date_change(::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, request_order_date_change_client_stub.call_count + end + end + end + + def test_configure + credentials_token = :dummy_value + + client = block_config = config = nil + dummy_stub = ClientStub.new nil + Gapic::Rest::ClientStub.stub :new, dummy_stub do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| + config.credentials = credentials_token + end + end + + config = client.configure do |c| + block_config = c + end + + assert_same block_config, config + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration, config + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb new file mode 100644 index 000000000000..112185b2e09a --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb @@ -0,0 +1,2554 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "helper" + +require "gapic/grpc/service_stub" + +require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" +require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" + +class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::ClientTest < Minitest::Test + class ClientStub + attr_accessor :call_rpc_count, :requests + + def initialize response, operation, &block + @response = response + @operation = operation + @block = block + @call_rpc_count = 0 + @requests = [] + end + + def call_rpc *args, **kwargs + @call_rpc_count += 1 + + @requests << @block&.call(*args, **kwargs) + + catch :response do + yield @response, @operation if block_given? + @response + end + end + + def endpoint + "endpoint.example.com" + end + + def universe_domain + "example.com" + end + + def stub_logger + nil + end + + def logger + nil + end + end + + def test_list_orders + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_orders_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_orders, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_orders_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_orders parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_orders ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_orders(::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_orders_client_stub.call_rpc_count + end + end + + def test_get_order + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_order({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_order name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_order ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_order({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_order(::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_order_client_stub.call_rpc_count + end + end + + def test_create_order + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + order_id = "hello world" + order = {} + request_id = "hello world" + + create_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["order_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Order), request["order"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_order parent: parent, order_id: order_id, order: order, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_order_client_stub.call_rpc_count + end + end + + def test_update_order + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + update_mask = {} + order = {} + request_id = "hello world" + + update_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :update_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, request + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Order), request["order"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, update_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.update_order({ update_mask: update_mask, order: order, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.update_order update_mask: update_mask, order: order, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.update_order ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.update_order({ update_mask: update_mask, order: order, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.update_order(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, update_order_client_stub.call_rpc_count + end + end + + def test_delete_order + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + force = true + + delete_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + assert_equal true, request["force"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_order({ name: name, request_id: request_id, force: force }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_order name: name, request_id: request_id, force: force do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_order ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_order({ name: name, request_id: request_id, force: force }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_order(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_order_client_stub.call_rpc_count + end + end + + def test_submit_order + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + type = :TYPE_UNSPECIFIED + + submit_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :submit_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + assert_equal :TYPE_UNSPECIFIED, request["type"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, submit_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.submit_order({ name: name, request_id: request_id, type: type }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.submit_order name: name, request_id: request_id, type: type do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.submit_order ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.submit_order({ name: name, request_id: request_id, type: type }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.submit_order(::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, submit_order_client_stub.call_rpc_count + end + end + + def test_cancel_order + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + cancel_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :cancel_order, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, cancel_order_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.cancel_order({ name: name, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.cancel_order name: name, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.cancel_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.cancel_order({ name: name, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.cancel_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, cancel_order_client_stub.call_rpc_count + end + end + + def test_list_sites + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_sites_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_sites, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_sites_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_sites parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_sites ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_sites(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_sites_client_stub.call_rpc_count + end + end + + def test_get_site + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_site, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_site({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_site name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_site ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_site({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_site(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_site_client_stub.call_rpc_count + end + end + + def test_create_site + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + site_id = "hello world" + site = {} + request_id = "hello world" + + create_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_site, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["site_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Site), request["site"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_site parent: parent, site_id: site_id, site: site, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_site ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_site(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_site_client_stub.call_rpc_count + end + end + + def test_update_site + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + update_mask = {} + site = {} + request_id = "hello world" + + update_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :update_site, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, request + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Site), request["site"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, update_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.update_site({ update_mask: update_mask, site: site, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.update_site update_mask: update_mask, site: site, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.update_site ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.update_site({ update_mask: update_mask, site: site, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.update_site(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, update_site_client_stub.call_rpc_count + end + end + + def test_delete_site + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_site, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_site_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_site({ name: name, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_site name: name, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_site ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_site({ name: name, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_site(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_site_client_stub.call_rpc_count + end + end + + def test_list_hardware_groups + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_hardware_groups_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_hardware_groups, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_hardware_groups_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_hardware_groups parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_hardware_groups ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_hardware_groups(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_hardware_groups_client_stub.call_rpc_count + end + end + + def test_get_hardware_group + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_hardware_group, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_hardware_group({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_hardware_group name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_hardware_group({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_hardware_group_client_stub.call_rpc_count + end + end + + def test_create_hardware_group + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + hardware_group_id = "hello world" + hardware_group = {} + request_id = "hello world" + + create_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_hardware_group, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["hardware_group_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup), request["hardware_group"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_hardware_group parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_hardware_group_client_stub.call_rpc_count + end + end + + def test_update_hardware_group + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + update_mask = {} + hardware_group = {} + request_id = "hello world" + + update_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :update_hardware_group, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, request + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup), request["hardware_group"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, update_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.update_hardware_group update_mask: update_mask, hardware_group: hardware_group, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.update_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.update_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, update_hardware_group_client_stub.call_rpc_count + end + end + + def test_delete_hardware_group + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_hardware_group, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_hardware_group_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_hardware_group({ name: name, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_hardware_group name: name, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_hardware_group({ name: name, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_hardware_group_client_stub.call_rpc_count + end + end + + def test_list_hardware + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_hardware, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_hardware parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_hardware_client_stub.call_rpc_count + end + end + + def test_get_hardware + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_hardware, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_hardware({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_hardware name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_hardware({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_hardware_client_stub.call_rpc_count + end + end + + def test_create_hardware + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + hardware_id = "hello world" + hardware = {} + + create_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_hardware, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["hardware_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware), request["hardware"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_hardware parent: parent, hardware_id: hardware_id, hardware: hardware do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_hardware_client_stub.call_rpc_count + end + end + + def test_update_hardware + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + update_mask = {} + hardware = {} + request_id = "hello world" + + update_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :update_hardware, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, request + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware), request["hardware"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, update_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.update_hardware update_mask: update_mask, hardware: hardware, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.update_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.update_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, update_hardware_client_stub.call_rpc_count + end + end + + def test_delete_hardware + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_hardware, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_hardware_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_hardware({ name: name, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_hardware name: name, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_hardware({ name: name, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_hardware_client_stub.call_rpc_count + end + end + + def test_list_comments + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_comments_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_comments, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_comments_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_comments parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_comments ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_comments(::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_comments_client_stub.call_rpc_count + end + end + + def test_get_comment + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_comment, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_comment({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_comment name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_comment({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_comment_client_stub.call_rpc_count + end + end + + def test_create_comment + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + comment_id = "hello world" + comment = {} + request_id = "hello world" + + create_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_comment, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["comment_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment), request["comment"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_comment parent: parent, comment_id: comment_id, comment: comment, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_comment_client_stub.call_rpc_count + end + end + + def test_record_action_on_comment + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + action_type = :ACTION_TYPE_UNSPECIFIED + + record_action_on_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :record_action_on_comment, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, request + assert_equal "hello world", request["name"] + assert_equal :ACTION_TYPE_UNSPECIFIED, request["action_type"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, record_action_on_comment_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.record_action_on_comment({ name: name, action_type: action_type }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.record_action_on_comment name: name, action_type: action_type do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.record_action_on_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.record_action_on_comment({ name: name, action_type: action_type }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.record_action_on_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, record_action_on_comment_client_stub.call_rpc_count + end + end + + def test_list_change_log_entries + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_change_log_entries_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_change_log_entries, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_change_log_entries_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_change_log_entries parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_change_log_entries ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_change_log_entries(::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_change_log_entries_client_stub.call_rpc_count + end + end + + def test_get_change_log_entry + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_change_log_entry_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_change_log_entry, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_change_log_entry_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_change_log_entry({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_change_log_entry name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_change_log_entry ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_change_log_entry({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_change_log_entry(::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_change_log_entry_client_stub.call_rpc_count + end + end + + def test_list_skus + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_skus_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_skus, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_skus_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_skus parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_skus ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_skus(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_skus_client_stub.call_rpc_count + end + end + + def test_get_sku + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_sku_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_sku, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_sku_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_sku({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_sku name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_sku ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_sku({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_sku(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_sku_client_stub.call_rpc_count + end + end + + def test_list_zones + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_zones_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :list_zones, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, request + assert_equal "hello world", request["parent"] + assert_equal 42, request["page_size"] + assert_equal "hello world", request["page_token"] + assert_equal "hello world", request["filter"] + assert_equal "hello world", request["order_by"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, list_zones_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.list_zones parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.list_zones ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.list_zones(::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| + assert_kind_of Gapic::PagedEnumerable, response + assert_equal grpc_response, response.response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, list_zones_client_stub.call_rpc_count + end + end + + def test_get_zone + # Create GRPC objects. + grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :get_zone, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, request + assert_equal "hello world", request["name"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, get_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.get_zone({ name: name }) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use named arguments + client.get_zone name: name do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.get_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.get_zone({ name: name }, grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.get_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name), grpc_options) do |response, operation| + assert_equal grpc_response, response + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, get_zone_client_stub.call_rpc_count + end + end + + def test_create_zone + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + zone_id = "hello world" + zone = {} + request_id = "hello world" + + create_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :create_zone, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, request + assert_equal "hello world", request["parent"] + assert_equal "hello world", request["zone_id"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone), request["zone"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, create_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.create_zone parent: parent, zone_id: zone_id, zone: zone, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.create_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.create_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, create_zone_client_stub.call_rpc_count + end + end + + def test_update_zone + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + update_mask = {} + zone = {} + request_id = "hello world" + + update_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :update_zone, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, request + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone), request["zone"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, update_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.update_zone update_mask: update_mask, zone: zone, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.update_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.update_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, update_zone_client_stub.call_rpc_count + end + end + + def test_delete_zone + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :delete_zone, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, delete_zone_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.delete_zone({ name: name, request_id: request_id }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.delete_zone name: name, request_id: request_id do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.delete_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.delete_zone({ name: name, request_id: request_id }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.delete_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, delete_zone_client_stub.call_rpc_count + end + end + + def test_signal_zone_state + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + state_signal = :STATE_SIGNAL_UNSPECIFIED + provisioning_state_signal = :PROVISIONING_STATE_SIGNAL_UNSPECIFIED + step = "hello world" + details = "hello world" + + signal_zone_state_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :signal_zone_state, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, request + assert_equal "hello world", request["name"] + assert_equal "hello world", request["request_id"] + assert_equal :STATE_SIGNAL_UNSPECIFIED, request["state_signal"] + assert_equal :PROVISIONING_STATE_SIGNAL_UNSPECIFIED, request["provisioning_state_signal"] + assert_equal "hello world", request["step"] + assert_equal "hello world", request["details"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, signal_zone_state_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.signal_zone_state name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.signal_zone_state ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.signal_zone_state(::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, signal_zone_state_client_stub.call_rpc_count + end + end + + def test_request_order_date_change + # Create GRPC objects. + grpc_response = ::Google::Longrunning::Operation.new + grpc_operation = GRPC::ActiveCall::Operation.new nil + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + grpc_options = {} + + # Create request parameters for a unary method. + name = "hello world" + requested_date = {} + + request_order_date_change_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| + assert_equal :request_order_date_change, name + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, request + assert_equal "hello world", request["name"] + assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Type::Date), request["requested_date"] + refute_nil options + end + + Gapic::ServiceStub.stub :new, request_order_date_change_client_stub do + # Create client + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + + # Use hash object + client.request_order_date_change({ name: name, requested_date: requested_date }) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use named arguments + client.request_order_date_change name: name, requested_date: requested_date do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object + client.request_order_date_change ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use hash object with options + client.request_order_date_change({ name: name, requested_date: requested_date }, grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Use protobuf object with options + client.request_order_date_change(::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date), grpc_options) do |response, operation| + assert_kind_of Gapic::Operation, response + assert_equal grpc_response, response.grpc_op + assert_equal grpc_operation, operation + end + + # Verify method calls + assert_equal 5, request_order_date_change_client_stub.call_rpc_count + end + end + + def test_configure + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + + client = block_config = config = nil + dummy_stub = ClientStub.new nil, nil + Gapic::ServiceStub.stub :new, dummy_stub do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + end + + config = client.configure do |c| + block_config = c + end + + assert_same block_config, config + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration, config + end + + def test_credentials + key = OpenSSL::PKey::RSA.new 2048 + cred_json = { + "private_key" => key.to_pem, + "client_email" => "app@developer.gserviceaccount.com", + "type" => "service_account" + } + key_file = StringIO.new cred_json.to_json + creds = Google::Auth::ServiceAccountCredentials.make_creds({ json_key_io: key_file }) + + dummy_stub = ClientStub.new nil, nil + Gapic::ServiceStub.stub :new, dummy_stub do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = creds + end + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client, client + assert_equal creds, client.configure.credentials + end + end + + def test_operations_client + grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure + + client = nil + dummy_stub = ClientStub.new nil, nil + Gapic::ServiceStub.stub :new, dummy_stub do + client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| + config.credentials = grpc_channel + end + end + + assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations, client.operations_client + end +end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb new file mode 100644 index 000000000000..f0e715458fa2 --- /dev/null +++ b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb @@ -0,0 +1,25 @@ +# frozen_string_literal: true + +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "minitest/autorun" +require "minitest/focus" +require "minitest/rg" + +require "grpc" + +require "ostruct" From aff5e2df21bf2d3b3cd629b11277367b0338e675 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 5 Mar 2026 18:01:33 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- .../v1alpha/resources_pb.rb | 2 +- .../v1alpha/resources.rb | 3 + .../.gitignore | 22 - .../.repo-metadata.json | 18 - .../.rubocop.yml | 33 - .../.toys.rb | 28 - .../.yardopts | 12 - .../AUTHENTICATION.md | 122 - .../CHANGELOG.md | 2 - .../Gemfile | 11 - .../LICENSE.md | 201 - .../README.md | 154 - .../Rakefile | 169 - .../gapic_metadata.json | 203 - ...ud-gdc_hardware_management-v1alpha.gemspec | 29 - ...e-cloud-gdc_hardware_management-v1alpha.rb | 21 - .../cloud/gdc_hardware_management/v1alpha.rb | 45 - .../v1alpha/bindings_override.rb | 75 - .../v1alpha/gdc_hardware_management.rb | 56 - .../v1alpha/gdc_hardware_management/client.rb | 4499 ----------------- .../gdc_hardware_management/credentials.rb | 47 - .../gdc_hardware_management/operations.rb | 841 --- .../v1alpha/gdc_hardware_management/paths.rb | 208 - .../v1alpha/gdc_hardware_management/rest.rb | 54 - .../gdc_hardware_management/rest/client.rb | 4205 --------------- .../rest/operations.rb | 925 ---- .../rest/service_stub.rb | 2354 --------- .../gdc_hardware_management/v1alpha/rest.rb | 38 - .../v1alpha/version.rb | 28 - .../v1alpha/resources_pb.rb | 99 - .../v1alpha/service_pb.rb | 107 - .../v1alpha/service_services_pb.rb | 120 - .../proto_docs/README.md | 4 - .../proto_docs/google/api/client.rb | 473 -- .../proto_docs/google/api/field_behavior.rb | 85 - .../proto_docs/google/api/field_info.rb | 88 - .../proto_docs/google/api/launch_stage.rb | 71 - .../proto_docs/google/api/resource.rb | 227 - .../v1alpha/resources.rb | 1209 ----- .../gdchardwaremanagement/v1alpha/service.rb | 959 ---- .../google/longrunning/operations.rb | 191 - .../proto_docs/google/protobuf/any.rb | 145 - .../proto_docs/google/protobuf/duration.rb | 98 - .../proto_docs/google/protobuf/empty.rb | 34 - .../proto_docs/google/protobuf/field_mask.rb | 229 - .../proto_docs/google/protobuf/timestamp.rb | 127 - .../proto_docs/google/rpc/status.rb | 48 - .../proto_docs/google/type/date.rb | 53 - .../proto_docs/google/type/datetime.rb | 103 - .../proto_docs/google/type/dayofweek.rb | 49 - .../proto_docs/google/type/postal_address.rb | 135 - .../proto_docs/google/type/timeofday.rb | 45 - .../snippets/Gemfile | 32 - .../gdc_hardware_management/cancel_order.rb | 54 - .../gdc_hardware_management/create_comment.rb | 54 - .../create_hardware.rb | 54 - .../create_hardware_group.rb | 54 - .../gdc_hardware_management/create_order.rb | 54 - .../gdc_hardware_management/create_site.rb | 54 - .../gdc_hardware_management/create_zone.rb | 54 - .../delete_hardware.rb | 54 - .../delete_hardware_group.rb | 54 - .../gdc_hardware_management/delete_order.rb | 54 - .../gdc_hardware_management/delete_site.rb | 54 - .../gdc_hardware_management/delete_zone.rb | 54 - .../get_change_log_entry.rb | 47 - .../gdc_hardware_management/get_comment.rb | 47 - .../gdc_hardware_management/get_hardware.rb | 47 - .../get_hardware_group.rb | 47 - .../gdc_hardware_management/get_order.rb | 47 - .../gdc_hardware_management/get_site.rb | 47 - .../gdc_hardware_management/get_sku.rb | 47 - .../gdc_hardware_management/get_zone.rb | 47 - .../list_change_log_entries.rb | 51 - .../gdc_hardware_management/list_comments.rb | 51 - .../gdc_hardware_management/list_hardware.rb | 51 - .../list_hardware_groups.rb | 51 - .../gdc_hardware_management/list_orders.rb | 51 - .../gdc_hardware_management/list_sites.rb | 51 - .../gdc_hardware_management/list_skus.rb | 51 - .../gdc_hardware_management/list_zones.rb | 51 - .../record_action_on_comment.rb | 47 - .../request_order_date_change.rb | 54 - .../signal_zone_state.rb | 54 - .../gdc_hardware_management/submit_order.rb | 54 - .../update_hardware.rb | 54 - .../update_hardware_group.rb | 54 - .../gdc_hardware_management/update_order.rb | 54 - .../gdc_hardware_management/update_site.rb | 54 - .../gdc_hardware_management/update_zone.rb | 54 - ...e.cloud.gdchardwaremanagement.v1alpha.json | 1495 ------ ...gdc_hardware_management_operations_test.rb | 400 -- .../gdc_hardware_management_paths_test.rb | 151 - .../gdc_hardware_management_rest_test.rb | 2172 -------- .../v1alpha/gdc_hardware_management_test.rb | 2554 ---------- .../test/helper.rb | 25 - 96 files changed, 4 insertions(+), 27840 deletions(-) delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb delete mode 100644 owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb diff --git a/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb b/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb index 8513739dcc2d..ace5f72be29f 100644 --- a/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb +++ b/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb @@ -15,7 +15,7 @@ require 'google/type/timeofday_pb' -descriptor_data = "\n:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\x1a\x1agoogle/type/datetime.proto\x1a\x1bgoogle/type/dayofweek.proto\x1a google/type/postal_address.proto\x1a\x1bgoogle/type/timeofday.proto\"\xf6\x0f\n\x05Order\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\r \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12R\n\x06labels\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Order.LabelsEntryB\x03\xe0\x41\x01\x12K\n\x05state\x18\x05 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.Order.StateB\x03\xe0\x41\x03\x12\x62\n\x14organization_contact\x18\x06 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12\x1d\n\x10target_workloads\x18\x07 \x03(\tB\x03\xe0\x41\x01\x12 \n\x13\x63ustomer_motivation\x18\x08 \x01(\tB\x03\xe0\x41\x02\x12;\n\x10\x66ulfillment_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x05\x18\x01\xe0\x41\x01\x12\x44\n$customer_requested_installation_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x18\n\x0bregion_code\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x1b\n\x0eorder_form_uri\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12I\n\x04type\x18\x0c \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Order.TypeB\x03\xe0\x41\x03\x12\x34\n\x0bsubmit_time\x18\x0e \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x0f \x01(\tB\x03\xe0\x41\x03\x12\\\n\x11\x65xisting_hardware\x18\x10 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.HardwareLocationB\x03\xe0\x41\x01\x12^\n\x0f\x64\x65ployment_type\x18\x12 \x01(\x0e\x32@.google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentTypeB\x03\xe0\x41\x03\x12\x38\n\x18\x61\x63tual_installation_date\x18\x13 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12;\n\x1b\x65stimated_installation_date\x18\x14 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x16 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x16\n\tmigration\x18\x17 \x01(\x08\x42\x03\xe0\x41\x01\x12\x36\n\raccepted_time\x18\x18 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x35\n\x15requested_date_change\x18\x19 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x19\n\x0cvendor_notes\x18\x1a \x01(\tB\x03\xe0\x41\x03\x12\\\n\x0evendor_contact\x18\x1b \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xe4\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\t\n\x05\x44RAFT\x10\x01\x12\r\n\tSUBMITTED\x10\x02\x12\x11\n\rINFO_COMPLETE\x10\x0c\x12\x0c\n\x08\x41\x43\x43\x45PTED\x10\x03\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x04\x12\x0c\n\x08\x42UILDING\x10\x05\x12\x0c\n\x08SHIPPING\x10\x06\x12\x0e\n\nINSTALLING\x10\x07\x12\n\n\x06\x46\x41ILED\x10\x08\x12\x17\n\x13PARTIALLY_COMPLETED\x10\t\x12\r\n\tCOMPLETED\x10\n\x12\r\n\tCANCELLED\x10\x0b\"?\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04PAID\x10\x01\x12\x07\n\x03POC\x10\x02\x12\n\n\x06UNPAID\x10\x02\x1a\x02\x10\x01\"|\n\x0e\x44\x65ploymentType\x12\x1f\n\x1b\x44\x45PLOYMENT_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x46ULL_PRODUCTION\x10\x01\x12\x14\n\x10PROOF_OF_CONCEPT\x10\x02\x12\x0c\n\x08INTERNAL\x10\x03\x12\x10\n\x0c\x43USTOMER_LAB\x10\x04:v\xea\x41s\n*gdchardwaremanagement.googleapis.com/Order\x12\x36projects/{project}/locations/{location}/orders/{order}*\x06orders2\x05order\"\xbb\x05\n\x04Site\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x18 \x01(\tB\x03\xe0\x41\x01\x12\x18\n\x0b\x64\x65scription\x18\x19 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Site.LabelsEntryB\x03\xe0\x41\x01\x12\x62\n\x14organization_contact\x18\x05 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12 \n\x13google_maps_pin_uri\x18\x06 \x01(\tB\x03\xe0\x41\x01\x12Q\n\x0c\x61\x63\x63\x65ss_times\x18\x1a \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\x12\x12\n\x05notes\x18\x1b \x01(\tB\x03\xe0\x41\x01\x12\x1d\n\x10\x63ustomer_site_id\x18\x1c \x01(\tB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Site\x12\x34projects/{project}/locations/{location}/sites/{site}*\x05sites2\x04site\"\xec\x07\n\rHardwareGroup\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Z\n\x06labels\x18\x04 \x03(\x0b\x32\x45.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.LabelsEntryB\x03\xe0\x41\x01\x12\x1b\n\x0ehardware_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02\x12O\n\x06\x63onfig\x18\x06 \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12?\n\x04site\x18\x07 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12S\n\x05state\x18\x08 \x01(\x0e\x32?.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.StateB\x03\xe0\x41\x03\x12?\n\x04zone\x18\t \x01(\tB1\xe0\x41\x01\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12=\n\x1brequested_installation_date\x18\n \x01(\x0b\x32\x11.google.type.DateB\x05\x18\x01\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x9a\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\x17\n\x13PARTIALLY_INSTALLED\x10\x05\x12\r\n\tINSTALLED\x10\x06\x12\n\n\x06\x46\x41ILED\x10\x07:\xaf\x01\xea\x41\xab\x01\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12Vprojects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}*\x0ehardwareGroups2\rhardwareGroup\"\x99\x11\n\x08Hardware\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12U\n\x06labels\x18\x05 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.LabelsEntryB\x03\xe0\x41\x01\x12\x41\n\x05order\x18\x06 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12R\n\x0ehardware_group\x18\x07 \x01(\tB:\xe0\x41\x03\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12?\n\x04site\x18\x08 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12N\n\x05state\x18\t \x01(\x0e\x32:.google.cloud.gdchardwaremanagement.v1alpha.Hardware.StateB\x03\xe0\x41\x03\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12O\n\x06\x63onfig\x18\x0b \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12;\n\x1b\x65stimated_installation_date\x18\x0c \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rphysical_info\x18\r \x01(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfoB\x03\xe0\x41\x01\x12\x64\n\x11installation_info\x18\x0e \x01(\x0b\x32\x44.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfoB\x03\xe0\x41\x01\x12?\n\x04zone\x18\x0f \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12;\n\x1brequested_installation_date\x18\x10 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x38\n\x18\x61\x63tual_installation_date\x18\x11 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rmachine_infos\x18\x14 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfoB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x1a\xf1\x01\n\nMacAddress\x12\x14\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12^\n\x04type\x18\x02 \x01(\x0e\x32K.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressTypeB\x03\xe0\x41\x03\x12!\n\x0cipv4_address\x18\x03 \x01(\tB\x0b\xe0\x41\x03\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"J\n\x0b\x41\x64\x64ressType\x12\x1c\n\x18\x41\x44\x44RESS_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03NIC\x10\x01\x12\x07\n\x03\x42MC\x10\x02\x12\x0b\n\x07VIRTUAL\x10\x03\x1a\x9c\x01\n\x08\x44iskInfo\x12\x19\n\x0cmanufacturer\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04slot\x18\x02 \x01(\x05\x42\x03\xe0\x41\x03\x12\x1a\n\rserial_number\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04psid\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0bpart_number\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cmodel_number\x18\x06 \x01(\tB\x03\xe0\x41\x03\x1a\xef\x01\n\x0bMachineInfo\x12\x18\n\x0bservice_tag\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12[\n\rmac_addresses\x18\x02 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddressB\x03\xe0\x41\x03\x12\x11\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12V\n\ndisk_infos\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfoB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x81\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\r\n\tINSTALLED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06:\x84\x01\xea\x41\x80\x01\n-gdchardwaremanagement.googleapis.com/Hardware\x12;projects/{project}/locations/{location}/hardware/{hardware}*\x08hardware2\x08hardware\"\xa1\x04\n\x07\x43omment\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12T\n\x06labels\x18\x03 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Comment.LabelsEntryB\x03\xe0\x41\x01\x12\x13\n\x06\x61uthor\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04text\x18\x05 \x01(\tB\x03\xe0\x41\x02\x12=\n\x14\x63ustomer_viewed_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12N\n\rauthor_entity\x18\x07 \x01(\x0e\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.EntityB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\x90\x01\xea\x41\x8c\x01\n,gdchardwaremanagement.googleapis.com/Comment\x12Iprojects/{project}/locations/{location}/orders/{order}/comments/{comment}*\x08\x63omments2\x07\x63omment\"\xb1\x03\n\x0e\x43hangeLogEntry\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12[\n\x06labels\x18\x03 \x03(\x0b\x32\x46.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry.LabelsEntryB\x03\xe0\x41\x01\x12\x10\n\x03log\x18\x04 \x01(\tB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xb7\x01\xea\x41\xb3\x01\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12Zprojects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}*\x10\x63hangeLogEntries2\x0e\x63hangeLogEntry\"\x8a\x06\n\x03Sku\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12J\n\x06\x63onfig\x18\x06 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.SkuConfigB\x03\xe0\x41\x03\x12O\n\tinstances\x18\x07 \x03(\x0b\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.SkuInstanceB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x65scription\x18\x08 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0brevision_id\x18\t \x01(\tB\x03\xe0\x41\x03\x12\x16\n\tis_active\x18\n \x01(\x08\x42\x03\xe0\x41\x03\x12G\n\x04type\x18\x0b \x01(\x0e\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Sku.TypeB\x03\xe0\x41\x03\x12\x17\n\nvcpu_count\x18\x0c \x01(\x05\x42\x03\xe0\x41\x03\x12Y\n\x15hardware_count_ranges\x18\r \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.Sku.RangeB\x03\xe0\x41\x03\x1a!\n\x05Range\x12\x0b\n\x03min\x18\x01 \x01(\x05\x12\x0b\n\x03max\x18\x02 \x01(\x05\"2\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04RACK\x10\x01\x12\n\n\x06SERVER\x10\x02:l\xea\x41i\n(gdchardwaremanagement.googleapis.com/Sku\x12\x32projects/{project}/locations/{location}/skus/{sku}*\x04skus2\x03sku\"\x91\x0b\n\x04Zone\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Zone.LabelsEntryB\x03\xe0\x41\x01\x12\x19\n\x0c\x64isplay_name\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12J\n\x05state\x18\x08 \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Zone.StateB\x03\xe0\x41\x03\x12J\n\x08\x63ontacts\x18\t \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12Z\n\x0enetwork_config\x18\x0b \x01(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfigB\x03\xe0\x41\x01\x12\x1f\n\x12globally_unique_id\x18\x0c \x01(\tB\x03\xe0\x41\x03\x12\x61\n\x14subscription_configs\x18\r \x03(\x0b\x32>.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfigB\x03\xe0\x41\x03\x12\x63\n\x12provisioning_state\x18\x0e \x01(\x0e\x32\x42.google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningStateB\x03\xe0\x41\x03\x12&\n\x19skip_cluster_provisioning\x18\x10 \x01(\x08\x42\x03\xe0\x41\x01\x12$\n\x17\x63luster_intent_required\x18\x11 \x01(\x08\x42\x03\xe0\x41\x03\x12$\n\x17\x63luster_intent_verified\x18\x12 \x01(\x08\x42\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x84\x02\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\r\n\tPREPARING\x10\x02\x12,\n(READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS\x10\x05\x12*\n&CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED\x10\x08\x12\x19\n\x15READY_FOR_SITE_TURNUP\x10\x06\x12)\n%CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED\x10\x07\x12\n\n\x06\x41\x43TIVE\x10\x03\x12\r\n\tCANCELLED\x10\x04\"\x8b\x01\n\x11ProvisioningState\x12\"\n\x1ePROVISIONING_STATE_UNSPECIFIED\x10\x00\x12\x19\n\x15PROVISIONING_REQUIRED\x10\x01\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x02\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x03:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Zone\x12\x34projects/{project}/locations/{location}/zones/{zone}*\x05zones2\x04zone\"\xbb\x01\n\x13OrganizationContact\x12\x30\n\x07\x61\x64\x64ress\x18\x01 \x01(\x0b\x32\x1a.google.type.PostalAddressB\x03\xe0\x41\x02\x12\x12\n\x05\x65mail\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05phone\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12J\n\x08\x63ontacts\x18\x04 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\"\xe9\x01\n\x07\x43ontact\x12\x17\n\ngiven_name\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\x18\n\x0b\x66\x61mily_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x65mail\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x12\n\x05phone\x18\x04 \x01(\tB\x03\xe0\x41\x02\x12-\n\ttime_zone\x18\x05 \x01(\x0b\x32\x15.google.type.TimeZoneB\x03\xe0\x41\x01\x12T\n\x0freachable_times\x18\x06 \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\"\xce\x01\n\x0eHardwareConfig\x12=\n\x03sku\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\x12R\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupplyB\x03\xe0\x41\x02\x12)\n\x1csubscription_duration_months\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\"C\n\tSkuConfig\x12\x0b\n\x03\x63pu\x18\x01 \x01(\t\x12\x0b\n\x03gpu\x18\x02 \x01(\t\x12\x0b\n\x03ram\x18\x03 \x01(\t\x12\x0f\n\x07storage\x18\x04 \x01(\t\"\xca\x01\n\x0bSkuInstance\x12\x13\n\x0bregion_code\x18\x01 \x01(\t\x12M\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupply\x12\x13\n\x0b\x62illing_sku\x18\x03 \x01(\t\x12\x1c\n\x14\x62illing_sku_per_vcpu\x18\x04 \x01(\t\x12$\n\x1csubscription_duration_months\x18\x05 \x01(\x05\"\xa1\x06\n\x14HardwarePhysicalInfo\x12s\n\x10power_receptacle\x18\x01 \x01(\x0e\x32T.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleTypeB\x03\xe0\x41\x02\x12o\n\x0enetwork_uplink\x18\x02 \x01(\x0e\x32R.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkTypeB\x03\xe0\x41\x02\x12^\n\x07voltage\x18\x03 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.VoltageB\x03\xe0\x41\x02\x12^\n\x07\x61mperes\x18\x04 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.AmperesB\x03\xe0\x41\x02\"\xa3\x01\n\x13PowerReceptacleType\x12%\n!POWER_RECEPTACLE_TYPE_UNSPECIFIED\x10\x00\x12\r\n\tNEMA_5_15\x10\x01\x12\x08\n\x04\x43_13\x10\x02\x12\x13\n\x0bSTANDARD_EU\x10\x03\x1a\x02\x08\x01\x12\x11\n\rTYPE_G_BS1363\x10\x04\x12\x0b\n\x07\x43\x45\x45_7_3\x10\x05\x12\x0b\n\x07\x43\x45\x45_7_5\x10\x06\x12\n\n\x06TYPE_F\x10\x07\"C\n\x11NetworkUplinkType\x12#\n\x1fNETWORK_UPLINK_TYPE_UNSPECIFIED\x10\x00\x12\t\n\x05RJ_45\x10\x01\"D\n\x07Voltage\x12\x17\n\x13VOLTAGE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bVOLTAGE_110\x10\x01\x12\x0f\n\x0bVOLTAGE_220\x10\x03\"2\n\x07\x41mperes\x12\x17\n\x13\x41MPERES_UNSPECIFIED\x10\x00\x12\x0e\n\nAMPERES_15\x10\x01\"\xd5\x03\n\x18HardwareInstallationInfo\x12\x1a\n\rrack_location\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\"\n\x15power_distance_meters\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\x12#\n\x16switch_distance_meters\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02\x12Y\n\x14rack_unit_dimensions\x18\x04 \x01(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.DimensionsB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x05 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x02\x12\x65\n\track_type\x18\x06 \x01(\x0e\x32M.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackTypeB\x03\xe0\x41\x02\"B\n\x08RackType\x12\x19\n\x15RACK_TYPE_UNSPECIFIED\x10\x00\x12\x0c\n\x08TWO_POST\x10\x01\x12\r\n\tFOUR_POST\x10\x02\"\xb0\x03\n\x11ZoneNetworkConfig\x12,\n\x17machine_mgmt_ipv4_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1akubernetes_node_ipv4_range\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\x38\n#kubernetes_control_plane_ipv4_range\x18\x03 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12W\n\x16management_ipv4_subnet\x18\x04 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x02\x12W\n\x16kubernetes_ipv4_subnet\x18\x05 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x01\x12\'\n\x12\x64ns_ipv4_addresses\x18\x06 \x03(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\'\n\x1akubernetes_primary_vlan_id\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\"]\n\x06Subnet\x12\"\n\raddress_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1a\x64\x65\x66\x61ult_gateway_ip_address\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"\x97\x01\n\nTimePeriod\x12/\n\nstart_time\x18\x01 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12-\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12)\n\x04\x64\x61ys\x18\x03 \x03(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x02\"^\n\nDimensions\x12\x19\n\x0cwidth_inches\x18\x01 \x01(\x02\x42\x03\xe0\x41\x02\x12\x1a\n\rheight_inches\x18\x02 \x01(\x02\x42\x03\xe0\x41\x02\x12\x19\n\x0c\x64\x65pth_inches\x18\x03 \x01(\x02\x42\x03\xe0\x41\x02\"E\n\tRackSpace\x12\x1c\n\x0fstart_rack_unit\x18\x01 \x01(\x05\x42\x03\xe0\x41\x02\x12\x1a\n\rend_rack_unit\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\"\xbf\x01\n\x10HardwareLocation\x12?\n\x04site\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1a\n\rrack_location\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x03 \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x01\"\xb7\x02\n\x12SubscriptionConfig\x12\x1c\n\x0fsubscription_id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x64\n\x05state\x18\x03 \x01(\x0e\x32P.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionStateB\x03\xe0\x41\x03\"\x83\x01\n\x11SubscriptionState\x12\"\n\x1eSUBSCRIPTION_STATE_UNSPECIFIED\x10\x00\x12\n\n\x06\x41\x43TIVE\x10\x01\x12\x0c\n\x08INACTIVE\x10\x02\x12\t\n\x05\x45RROR\x10\x03\x12\x16\n\x12\x46\x41ILED_TO_RETRIEVE\x10\x04\x12\r\n\tCOMPLETED\x10\x05*U\n\x0bPowerSupply\x12\x1c\n\x18POWER_SUPPLY_UNSPECIFIED\x10\x00\x12\x13\n\x0fPOWER_SUPPLY_AC\x10\x01\x12\x13\n\x0fPOWER_SUPPLY_DC\x10\x02*F\n\x06\x45ntity\x12\x16\n\x12\x45NTITY_UNSPECIFIED\x10\x00\x12\n\n\x06GOOGLE\x10\x01\x12\x0c\n\x08\x43USTOMER\x10\x02\x12\n\n\x06VENDOR\x10\x03\x42\xb2\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0eResourcesProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" +descriptor_data = "\n:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\x1a\x1agoogle/type/datetime.proto\x1a\x1bgoogle/type/dayofweek.proto\x1a google/type/postal_address.proto\x1a\x1bgoogle/type/timeofday.proto\"\xf6\x0f\n\x05Order\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\r \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12R\n\x06labels\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Order.LabelsEntryB\x03\xe0\x41\x01\x12K\n\x05state\x18\x05 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.Order.StateB\x03\xe0\x41\x03\x12\x62\n\x14organization_contact\x18\x06 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12\x1d\n\x10target_workloads\x18\x07 \x03(\tB\x03\xe0\x41\x01\x12 \n\x13\x63ustomer_motivation\x18\x08 \x01(\tB\x03\xe0\x41\x02\x12;\n\x10\x66ulfillment_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x05\x18\x01\xe0\x41\x01\x12\x44\n$customer_requested_installation_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x18\n\x0bregion_code\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x1b\n\x0eorder_form_uri\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12I\n\x04type\x18\x0c \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Order.TypeB\x03\xe0\x41\x03\x12\x34\n\x0bsubmit_time\x18\x0e \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x0f \x01(\tB\x03\xe0\x41\x03\x12\\\n\x11\x65xisting_hardware\x18\x10 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.HardwareLocationB\x03\xe0\x41\x01\x12^\n\x0f\x64\x65ployment_type\x18\x12 \x01(\x0e\x32@.google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentTypeB\x03\xe0\x41\x03\x12\x38\n\x18\x61\x63tual_installation_date\x18\x13 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12;\n\x1b\x65stimated_installation_date\x18\x14 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x16 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x16\n\tmigration\x18\x17 \x01(\x08\x42\x03\xe0\x41\x01\x12\x36\n\raccepted_time\x18\x18 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x35\n\x15requested_date_change\x18\x19 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x19\n\x0cvendor_notes\x18\x1a \x01(\tB\x03\xe0\x41\x03\x12\\\n\x0evendor_contact\x18\x1b \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xe4\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\t\n\x05\x44RAFT\x10\x01\x12\r\n\tSUBMITTED\x10\x02\x12\x11\n\rINFO_COMPLETE\x10\x0c\x12\x0c\n\x08\x41\x43\x43\x45PTED\x10\x03\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x04\x12\x0c\n\x08\x42UILDING\x10\x05\x12\x0c\n\x08SHIPPING\x10\x06\x12\x0e\n\nINSTALLING\x10\x07\x12\n\n\x06\x46\x41ILED\x10\x08\x12\x17\n\x13PARTIALLY_COMPLETED\x10\t\x12\r\n\tCOMPLETED\x10\n\x12\r\n\tCANCELLED\x10\x0b\"?\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04PAID\x10\x01\x12\x07\n\x03POC\x10\x02\x12\n\n\x06UNPAID\x10\x02\x1a\x02\x10\x01\"|\n\x0e\x44\x65ploymentType\x12\x1f\n\x1b\x44\x45PLOYMENT_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x46ULL_PRODUCTION\x10\x01\x12\x14\n\x10PROOF_OF_CONCEPT\x10\x02\x12\x0c\n\x08INTERNAL\x10\x03\x12\x10\n\x0c\x43USTOMER_LAB\x10\x04:v\xea\x41s\n*gdchardwaremanagement.googleapis.com/Order\x12\x36projects/{project}/locations/{location}/orders/{order}*\x06orders2\x05order\"\xbb\x05\n\x04Site\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x18 \x01(\tB\x03\xe0\x41\x01\x12\x18\n\x0b\x64\x65scription\x18\x19 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Site.LabelsEntryB\x03\xe0\x41\x01\x12\x62\n\x14organization_contact\x18\x05 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12 \n\x13google_maps_pin_uri\x18\x06 \x01(\tB\x03\xe0\x41\x01\x12Q\n\x0c\x61\x63\x63\x65ss_times\x18\x1a \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\x12\x12\n\x05notes\x18\x1b \x01(\tB\x03\xe0\x41\x01\x12\x1d\n\x10\x63ustomer_site_id\x18\x1c \x01(\tB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Site\x12\x34projects/{project}/locations/{location}/sites/{site}*\x05sites2\x04site\"\xec\x07\n\rHardwareGroup\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Z\n\x06labels\x18\x04 \x03(\x0b\x32\x45.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.LabelsEntryB\x03\xe0\x41\x01\x12\x1b\n\x0ehardware_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02\x12O\n\x06\x63onfig\x18\x06 \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12?\n\x04site\x18\x07 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12S\n\x05state\x18\x08 \x01(\x0e\x32?.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.StateB\x03\xe0\x41\x03\x12?\n\x04zone\x18\t \x01(\tB1\xe0\x41\x01\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12=\n\x1brequested_installation_date\x18\n \x01(\x0b\x32\x11.google.type.DateB\x05\x18\x01\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x9a\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\x17\n\x13PARTIALLY_INSTALLED\x10\x05\x12\r\n\tINSTALLED\x10\x06\x12\n\n\x06\x46\x41ILED\x10\x07:\xaf\x01\xea\x41\xab\x01\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12Vprojects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}*\x0ehardwareGroups2\rhardwareGroup\"\x99\x11\n\x08Hardware\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12U\n\x06labels\x18\x05 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.LabelsEntryB\x03\xe0\x41\x01\x12\x41\n\x05order\x18\x06 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12R\n\x0ehardware_group\x18\x07 \x01(\tB:\xe0\x41\x03\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12?\n\x04site\x18\x08 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12N\n\x05state\x18\t \x01(\x0e\x32:.google.cloud.gdchardwaremanagement.v1alpha.Hardware.StateB\x03\xe0\x41\x03\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12O\n\x06\x63onfig\x18\x0b \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12;\n\x1b\x65stimated_installation_date\x18\x0c \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rphysical_info\x18\r \x01(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfoB\x03\xe0\x41\x01\x12\x64\n\x11installation_info\x18\x0e \x01(\x0b\x32\x44.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfoB\x03\xe0\x41\x01\x12?\n\x04zone\x18\x0f \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12;\n\x1brequested_installation_date\x18\x10 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x38\n\x18\x61\x63tual_installation_date\x18\x11 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rmachine_infos\x18\x14 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfoB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x1a\xf1\x01\n\nMacAddress\x12\x14\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12^\n\x04type\x18\x02 \x01(\x0e\x32K.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressTypeB\x03\xe0\x41\x03\x12!\n\x0cipv4_address\x18\x03 \x01(\tB\x0b\xe0\x41\x03\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"J\n\x0b\x41\x64\x64ressType\x12\x1c\n\x18\x41\x44\x44RESS_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03NIC\x10\x01\x12\x07\n\x03\x42MC\x10\x02\x12\x0b\n\x07VIRTUAL\x10\x03\x1a\x9c\x01\n\x08\x44iskInfo\x12\x19\n\x0cmanufacturer\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04slot\x18\x02 \x01(\x05\x42\x03\xe0\x41\x03\x12\x1a\n\rserial_number\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04psid\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0bpart_number\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cmodel_number\x18\x06 \x01(\tB\x03\xe0\x41\x03\x1a\xef\x01\n\x0bMachineInfo\x12\x18\n\x0bservice_tag\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12[\n\rmac_addresses\x18\x02 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddressB\x03\xe0\x41\x03\x12\x11\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12V\n\ndisk_infos\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfoB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x81\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\r\n\tINSTALLED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06:\x84\x01\xea\x41\x80\x01\n-gdchardwaremanagement.googleapis.com/Hardware\x12;projects/{project}/locations/{location}/hardware/{hardware}*\x08hardware2\x08hardware\"\xa1\x04\n\x07\x43omment\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12T\n\x06labels\x18\x03 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Comment.LabelsEntryB\x03\xe0\x41\x01\x12\x13\n\x06\x61uthor\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04text\x18\x05 \x01(\tB\x03\xe0\x41\x02\x12=\n\x14\x63ustomer_viewed_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12N\n\rauthor_entity\x18\x07 \x01(\x0e\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.EntityB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\x90\x01\xea\x41\x8c\x01\n,gdchardwaremanagement.googleapis.com/Comment\x12Iprojects/{project}/locations/{location}/orders/{order}/comments/{comment}*\x08\x63omments2\x07\x63omment\"\xb1\x03\n\x0e\x43hangeLogEntry\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12[\n\x06labels\x18\x03 \x03(\x0b\x32\x46.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry.LabelsEntryB\x03\xe0\x41\x01\x12\x10\n\x03log\x18\x04 \x01(\tB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xb7\x01\xea\x41\xb3\x01\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12Zprojects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}*\x10\x63hangeLogEntries2\x0e\x63hangeLogEntry\"\x8a\x06\n\x03Sku\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12J\n\x06\x63onfig\x18\x06 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.SkuConfigB\x03\xe0\x41\x03\x12O\n\tinstances\x18\x07 \x03(\x0b\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.SkuInstanceB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x65scription\x18\x08 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0brevision_id\x18\t \x01(\tB\x03\xe0\x41\x03\x12\x16\n\tis_active\x18\n \x01(\x08\x42\x03\xe0\x41\x03\x12G\n\x04type\x18\x0b \x01(\x0e\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Sku.TypeB\x03\xe0\x41\x03\x12\x17\n\nvcpu_count\x18\x0c \x01(\x05\x42\x03\xe0\x41\x03\x12Y\n\x15hardware_count_ranges\x18\r \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.Sku.RangeB\x03\xe0\x41\x03\x1a!\n\x05Range\x12\x0b\n\x03min\x18\x01 \x01(\x05\x12\x0b\n\x03max\x18\x02 \x01(\x05\"2\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04RACK\x10\x01\x12\n\n\x06SERVER\x10\x02:l\xea\x41i\n(gdchardwaremanagement.googleapis.com/Sku\x12\x32projects/{project}/locations/{location}/skus/{sku}*\x04skus2\x03sku\"\x9e\x0b\n\x04Zone\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Zone.LabelsEntryB\x03\xe0\x41\x01\x12\x19\n\x0c\x64isplay_name\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12J\n\x05state\x18\x08 \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Zone.StateB\x03\xe0\x41\x03\x12J\n\x08\x63ontacts\x18\t \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12Z\n\x0enetwork_config\x18\x0b \x01(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfigB\x03\xe0\x41\x01\x12\x1f\n\x12globally_unique_id\x18\x0c \x01(\tB\x03\xe0\x41\x03\x12\x61\n\x14subscription_configs\x18\r \x03(\x0b\x32>.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfigB\x03\xe0\x41\x03\x12\x63\n\x12provisioning_state\x18\x0e \x01(\x0e\x32\x42.google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningStateB\x03\xe0\x41\x03\x12&\n\x19skip_cluster_provisioning\x18\x10 \x01(\x08\x42\x03\xe0\x41\x01\x12$\n\x17\x63luster_intent_required\x18\x11 \x01(\x08\x42\x03\xe0\x41\x03\x12$\n\x17\x63luster_intent_verified\x18\x12 \x01(\x08\x42\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x91\x02\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\r\n\tPREPARING\x10\x02\x12,\n(READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS\x10\x05\x12*\n&CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED\x10\x08\x12\x19\n\x15READY_FOR_SITE_TURNUP\x10\x06\x12\x0b\n\x07OFFLINE\x10\t\x12)\n%CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED\x10\x07\x12\n\n\x06\x41\x43TIVE\x10\x03\x12\r\n\tCANCELLED\x10\x04\"\x8b\x01\n\x11ProvisioningState\x12\"\n\x1ePROVISIONING_STATE_UNSPECIFIED\x10\x00\x12\x19\n\x15PROVISIONING_REQUIRED\x10\x01\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x02\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x03:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Zone\x12\x34projects/{project}/locations/{location}/zones/{zone}*\x05zones2\x04zone\"\xbb\x01\n\x13OrganizationContact\x12\x30\n\x07\x61\x64\x64ress\x18\x01 \x01(\x0b\x32\x1a.google.type.PostalAddressB\x03\xe0\x41\x02\x12\x12\n\x05\x65mail\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05phone\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12J\n\x08\x63ontacts\x18\x04 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\"\xe9\x01\n\x07\x43ontact\x12\x17\n\ngiven_name\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\x18\n\x0b\x66\x61mily_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x65mail\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x12\n\x05phone\x18\x04 \x01(\tB\x03\xe0\x41\x02\x12-\n\ttime_zone\x18\x05 \x01(\x0b\x32\x15.google.type.TimeZoneB\x03\xe0\x41\x01\x12T\n\x0freachable_times\x18\x06 \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\"\xce\x01\n\x0eHardwareConfig\x12=\n\x03sku\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\x12R\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupplyB\x03\xe0\x41\x02\x12)\n\x1csubscription_duration_months\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\"C\n\tSkuConfig\x12\x0b\n\x03\x63pu\x18\x01 \x01(\t\x12\x0b\n\x03gpu\x18\x02 \x01(\t\x12\x0b\n\x03ram\x18\x03 \x01(\t\x12\x0f\n\x07storage\x18\x04 \x01(\t\"\xca\x01\n\x0bSkuInstance\x12\x13\n\x0bregion_code\x18\x01 \x01(\t\x12M\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupply\x12\x13\n\x0b\x62illing_sku\x18\x03 \x01(\t\x12\x1c\n\x14\x62illing_sku_per_vcpu\x18\x04 \x01(\t\x12$\n\x1csubscription_duration_months\x18\x05 \x01(\x05\"\xa1\x06\n\x14HardwarePhysicalInfo\x12s\n\x10power_receptacle\x18\x01 \x01(\x0e\x32T.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleTypeB\x03\xe0\x41\x02\x12o\n\x0enetwork_uplink\x18\x02 \x01(\x0e\x32R.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkTypeB\x03\xe0\x41\x02\x12^\n\x07voltage\x18\x03 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.VoltageB\x03\xe0\x41\x02\x12^\n\x07\x61mperes\x18\x04 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.AmperesB\x03\xe0\x41\x02\"\xa3\x01\n\x13PowerReceptacleType\x12%\n!POWER_RECEPTACLE_TYPE_UNSPECIFIED\x10\x00\x12\r\n\tNEMA_5_15\x10\x01\x12\x08\n\x04\x43_13\x10\x02\x12\x13\n\x0bSTANDARD_EU\x10\x03\x1a\x02\x08\x01\x12\x11\n\rTYPE_G_BS1363\x10\x04\x12\x0b\n\x07\x43\x45\x45_7_3\x10\x05\x12\x0b\n\x07\x43\x45\x45_7_5\x10\x06\x12\n\n\x06TYPE_F\x10\x07\"C\n\x11NetworkUplinkType\x12#\n\x1fNETWORK_UPLINK_TYPE_UNSPECIFIED\x10\x00\x12\t\n\x05RJ_45\x10\x01\"D\n\x07Voltage\x12\x17\n\x13VOLTAGE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bVOLTAGE_110\x10\x01\x12\x0f\n\x0bVOLTAGE_220\x10\x03\"2\n\x07\x41mperes\x12\x17\n\x13\x41MPERES_UNSPECIFIED\x10\x00\x12\x0e\n\nAMPERES_15\x10\x01\"\xd5\x03\n\x18HardwareInstallationInfo\x12\x1a\n\rrack_location\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\"\n\x15power_distance_meters\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\x12#\n\x16switch_distance_meters\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02\x12Y\n\x14rack_unit_dimensions\x18\x04 \x01(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.DimensionsB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x05 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x02\x12\x65\n\track_type\x18\x06 \x01(\x0e\x32M.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackTypeB\x03\xe0\x41\x02\"B\n\x08RackType\x12\x19\n\x15RACK_TYPE_UNSPECIFIED\x10\x00\x12\x0c\n\x08TWO_POST\x10\x01\x12\r\n\tFOUR_POST\x10\x02\"\xb0\x03\n\x11ZoneNetworkConfig\x12,\n\x17machine_mgmt_ipv4_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1akubernetes_node_ipv4_range\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\x38\n#kubernetes_control_plane_ipv4_range\x18\x03 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12W\n\x16management_ipv4_subnet\x18\x04 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x02\x12W\n\x16kubernetes_ipv4_subnet\x18\x05 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x01\x12\'\n\x12\x64ns_ipv4_addresses\x18\x06 \x03(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\'\n\x1akubernetes_primary_vlan_id\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\"]\n\x06Subnet\x12\"\n\raddress_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1a\x64\x65\x66\x61ult_gateway_ip_address\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"\x97\x01\n\nTimePeriod\x12/\n\nstart_time\x18\x01 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12-\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12)\n\x04\x64\x61ys\x18\x03 \x03(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x02\"^\n\nDimensions\x12\x19\n\x0cwidth_inches\x18\x01 \x01(\x02\x42\x03\xe0\x41\x02\x12\x1a\n\rheight_inches\x18\x02 \x01(\x02\x42\x03\xe0\x41\x02\x12\x19\n\x0c\x64\x65pth_inches\x18\x03 \x01(\x02\x42\x03\xe0\x41\x02\"E\n\tRackSpace\x12\x1c\n\x0fstart_rack_unit\x18\x01 \x01(\x05\x42\x03\xe0\x41\x02\x12\x1a\n\rend_rack_unit\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\"\xbf\x01\n\x10HardwareLocation\x12?\n\x04site\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1a\n\rrack_location\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x03 \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x01\"\xb7\x02\n\x12SubscriptionConfig\x12\x1c\n\x0fsubscription_id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x64\n\x05state\x18\x03 \x01(\x0e\x32P.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionStateB\x03\xe0\x41\x03\"\x83\x01\n\x11SubscriptionState\x12\"\n\x1eSUBSCRIPTION_STATE_UNSPECIFIED\x10\x00\x12\n\n\x06\x41\x43TIVE\x10\x01\x12\x0c\n\x08INACTIVE\x10\x02\x12\t\n\x05\x45RROR\x10\x03\x12\x16\n\x12\x46\x41ILED_TO_RETRIEVE\x10\x04\x12\r\n\tCOMPLETED\x10\x05*U\n\x0bPowerSupply\x12\x1c\n\x18POWER_SUPPLY_UNSPECIFIED\x10\x00\x12\x13\n\x0fPOWER_SUPPLY_AC\x10\x01\x12\x13\n\x0fPOWER_SUPPLY_DC\x10\x02*F\n\x06\x45ntity\x12\x16\n\x12\x45NTITY_UNSPECIFIED\x10\x00\x12\n\n\x06GOOGLE\x10\x01\x12\x0c\n\x08\x43USTOMER\x10\x02\x12\n\n\x06VENDOR\x10\x03\x42\xb2\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0eResourcesProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" pool = Google::Protobuf::DescriptorPool.generated_pool diff --git a/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb b/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb index f19eb338c8d4..0b49050f6aca 100644 --- a/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb +++ b/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb @@ -771,6 +771,9 @@ module State # The Zone is ready for site turnup. READY_FOR_SITE_TURNUP = 6 + # The Zone is offline. + OFFLINE = 9 + # The Zone failed in factory turnup checks. CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED = 7 diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore deleted file mode 100644 index 0135b6bc6cfc..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.gitignore +++ /dev/null @@ -1,22 +0,0 @@ -# Ignore bundler lockfiles -Gemfile.lock -gems.locked - -# Ignore documentation output -doc/* -.yardoc/* - -# Ignore test output -coverage/* - -# Ignore build artifacts -pkg/* - -# Ignore files commonly present in certain dev environments -.vagrant -.DS_STORE -.idea -*.iml - -# Ignore synth output -__pycache__ diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json deleted file mode 100644 index d9135f143ae9..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.repo-metadata.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "api_id": "gdchardwaremanagement.googleapis.com", - "api_shortname": "gdchardwaremanagement", - "client_documentation": "https://cloud.google.com/ruby/docs/reference/google-cloud-gdc_hardware_management-v1alpha/latest", - "distribution_name": "google-cloud-gdc_hardware_management-v1alpha", - "is_cloud": true, - "language": "ruby", - "name": "gdchardwaremanagement", - "name_pretty": "GDC Hardware Management V1ALPHA API", - "product_documentation": "https://cloud.google.com/distributed-cloud/edge/latest/docs", - "release_level": "unreleased", - "repo": "googleapis/google-cloud-ruby", - "requires_billing": true, - "ruby-cloud-description": "google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. Note that google-cloud-gdc_hardware_management-v1alpha is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-gdc_hardware_management instead. See the readme for more details.", - "ruby-cloud-product-url": "https://cloud.google.com/distributed-cloud/edge/latest/docs", - "ruby-cloud-service-override": "GdcHardwareManagement=GDCHardwareManagement", - "library_type": "GAPIC_AUTO" -} diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml deleted file mode 100644 index 7c5bd6fa2fa0..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.rubocop.yml +++ /dev/null @@ -1,33 +0,0 @@ -inherit_gem: - google-style: google-style.yml - -AllCops: - Exclude: - - "google-cloud-gdc_hardware_management-v1alpha.gemspec" - - "lib/**/*_pb.rb" - - "proto_docs/**/*" - - "test/**/*" - - "acceptance/**/*" - - "samples/acceptance/**/*" - - "Rakefile" - -Layout/LineLength: - Enabled: false -Metrics/AbcSize: - Enabled: false -Metrics/ClassLength: - Enabled: false -Metrics/CyclomaticComplexity: - Enabled: false -Metrics/MethodLength: - Enabled: false -Metrics/ModuleLength: - Enabled: false -Metrics/PerceivedComplexity: - Enabled: false -Naming/AccessorMethodName: - Exclude: - - "snippets/**/*.rb" -Naming/FileName: - Exclude: - - "lib/google-cloud-gdc_hardware_management-v1alpha.rb" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb deleted file mode 100644 index 177e22456e8a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.toys.rb +++ /dev/null @@ -1,28 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -toys_version! ">= 0.15.3" - -if ENV["RUBY_COMMON_TOOLS"] - common_tools_dir = File.expand_path ENV["RUBY_COMMON_TOOLS"] - load File.join(common_tools_dir, "toys", "gapic") -else - load_git remote: "https://github.com/googleapis/ruby-common-tools.git", - path: "toys/gapic", - update: true -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts deleted file mode 100644 index eda2091db73f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/.yardopts +++ /dev/null @@ -1,12 +0,0 @@ ---no-private ---title="GDC Hardware Management V1ALPHA API" ---exclude _pb\.rb$ ---markup markdown ---markup-provider redcarpet - -./lib/**/*.rb -./proto_docs/**/*.rb -- -README.md -LICENSE.md -AUTHENTICATION.md diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md deleted file mode 100644 index 870900569f1a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/AUTHENTICATION.md +++ /dev/null @@ -1,122 +0,0 @@ -# Authentication - -The recommended way to authenticate to the google-cloud-gdc_hardware_management-v1alpha library is to use -[Application Default Credentials (ADC)](https://cloud.google.com/docs/authentication/application-default-credentials). -To review all of your authentication options, see [Credentials lookup](#credential-lookup). - -## Quickstart - -The following example shows how to set up authentication for a local development -environment with your user credentials. - -**NOTE:** This method is _not_ recommended for running in production. User credentials -should be used only during development. - -1. [Download and install the Google Cloud CLI](https://cloud.google.com/sdk). -2. Set up a local ADC file with your user credentials: - -```sh -gcloud auth application-default login -``` - -3. Write code as if already authenticated. - -For more information about setting up authentication for a local development environment, see -[Set up Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-dev). - -## Credential Lookup - -The google-cloud-gdc_hardware_management-v1alpha library provides several mechanisms to configure your system. -Generally, using Application Default Credentials to facilitate automatic -credentials discovery is the easist method. But if you need to explicitly specify -credentials, there are several methods available to you. - -Credentials are accepted in the following ways, in the following order or precedence: - -1. Credentials specified in method arguments -2. Credentials specified in configuration -3. Credentials pointed to or included in environment variables -4. Credentials found in local ADC file -5. Credentials returned by the metadata server for the attached service account (GCP) - -### Configuration - -You can configure a path to a JSON credentials file, either for an individual client object or -globally, for all client objects. The JSON file can contain credentials created for -[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), -[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a -[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). - -Note: Service account keys are a security risk if not managed correctly. You should -[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) -whenever possible. - -To configure a credentials file for an individual client initialization: - -```ruby -require "google/cloud/gdc_hardware_management/v1alpha" - -client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = "path/to/credentialfile.json" -end -``` - -To configure a credentials file globally for all clients: - -```ruby -require "google/cloud/gdc_hardware_management/v1alpha" - -::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| - config.credentials = "path/to/credentialfile.json" -end - -client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new -``` - -### Environment Variables - -You can also use an environment variable to provide a JSON credentials file. -The environment variable can contain a path to the credentials file or, for -environments such as Docker containers where writing files is not encouraged, -you can include the credentials file itself. - -The JSON file can contain credentials created for -[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), -[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a -[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). - -Note: Service account keys are a security risk if not managed correctly. You should -[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) -whenever possible. - -The environment variables that google-cloud-gdc_hardware_management-v1alpha -checks for credentials are: - -* `GOOGLE_CLOUD_CREDENTIALS` - Path to JSON file, or JSON contents -* `GOOGLE_APPLICATION_CREDENTIALS` - Path to JSON file - -```ruby -require "google/cloud/gdc_hardware_management/v1alpha" - -ENV["GOOGLE_APPLICATION_CREDENTIALS"] = "path/to/credentialfile.json" - -client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new -``` - -### Local ADC file - -You can set up a local ADC file with your user credentials for authentication during -development. If credentials are not provided in code or in environment variables, -then the local ADC credentials are discovered. - -Follow the steps in [Quickstart](#quickstart) to set up a local ADC file. - -### Google Cloud Platform environments - -When running on Google Cloud Platform (GCP), including Google Compute Engine -(GCE), Google Kubernetes Engine (GKE), Google App Engine (GAE), Google Cloud -Functions (GCF) and Cloud Run, credentials are retrieved from the attached -service account automatically. Code should be written as if already authenticated. - -For more information, see -[Set up ADC for Google Cloud services](https://cloud.google.com/docs/authentication/provide-credentials-adc#attached-sa). diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md deleted file mode 100644 index f88957a62ba2..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/CHANGELOG.md +++ /dev/null @@ -1,2 +0,0 @@ -# Release History - diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile deleted file mode 100644 index 6442df18fa2f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Gemfile +++ /dev/null @@ -1,11 +0,0 @@ -source "https://rubygems.org" - -gemspec - -gem "google-style", "~> 1.31.1" -gem "minitest", "~> 5.22" -gem "minitest-focus", "~> 1.4" -gem "minitest-rg", "~> 5.3" -gem "rake", ">= 13.0" -gem "redcarpet", "~> 3.6" -gem "yard", "~> 0.9" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md deleted file mode 100644 index c261857ba6ad..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/LICENSE.md +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md deleted file mode 100644 index ef5d1772230c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/README.md +++ /dev/null @@ -1,154 +0,0 @@ -# Ruby Client for the GDC Hardware Management V1ALPHA API - -API Client library for the GDC Hardware Management V1ALPHA API - -google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. - -https://github.com/googleapis/google-cloud-ruby - -This gem is a _versioned_ client. It provides basic client classes for a -specific version of the GDC Hardware Management V1ALPHA API. Most users should consider using -the main client gem, -[google-cloud-gdc_hardware_management](https://rubygems.org/gems/google-cloud-gdc_hardware_management). -See the section below titled *Which client should I use?* for more information. - -## Installation - -``` -$ gem install google-cloud-gdc_hardware_management-v1alpha -``` - -## Before You Begin - -In order to use this library, you first need to go through the following steps: - -1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project) -1. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project) -1. [Enable the API.](https://console.cloud.google.com/apis/library/gdchardwaremanagement.googleapis.com) -1. [Set up authentication.](AUTHENTICATION.md) - -## Quick Start - -```ruby -require "google/cloud/gdc_hardware_management/v1alpha" - -client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new -request = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new # (request fields as keyword arguments...) -response = client.list_orders request -``` - -View the [Client Library Documentation](https://cloud.google.com/ruby/docs/reference/google-cloud-gdc_hardware_management-v1alpha/latest) -for class and method documentation. - -See also the [Product Documentation](https://cloud.google.com/distributed-cloud/edge/latest/docs) -for general usage information. - -## Debug Logging - -This library comes with opt-in Debug Logging that can help you troubleshoot -your application's integration with the API. When logging is activated, key -events such as requests and responses, along with data payloads and metadata -such as headers and client configuration, are logged to the standard error -stream. - -**WARNING:** Client Library Debug Logging includes your data payloads in -plaintext, which could include sensitive data such as PII for yourself or your -customers, private keys, or other security data that could be compromising if -leaked. Always practice good data hygiene with your application logs, and follow -the principle of least access. Google also recommends that Client Library Debug -Logging be enabled only temporarily during active debugging, and not used -permanently in production. - -To enable logging, set the environment variable `GOOGLE_SDK_RUBY_LOGGING_GEMS` -to the value `all`. Alternatively, you can set the value to a comma-delimited -list of client library gem names. This will select the default logging behavior, -which writes logs to the standard error stream. On a local workstation, this may -result in logs appearing on the console. When running on a Google Cloud hosting -service such as [Google Cloud Run](https://cloud.google.com/run), this generally -results in logs appearing alongside your application logs in the -[Google Cloud Logging](https://cloud.google.com/logging/) service. - -You can customize logging by modifying the `logger` configuration when -constructing a client object. For example: - -```ruby -require "google/cloud/gdc_hardware_management/v1alpha" -require "logger" - -client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.logger = Logger.new "my-app.log" -end -``` - -## Google Cloud Samples - -To browse ready to use code samples check [Google Cloud Samples](https://cloud.google.com/docs/samples). - -## Supported Ruby Versions - -This library is supported on Ruby 3.0+. - -Google provides official support for Ruby versions that are actively supported -by Ruby Core—that is, Ruby versions that are either in normal maintenance or -in security maintenance, and not end of life. Older versions of Ruby _may_ -still work, but are unsupported and not recommended. See -https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby -support schedule. - -## Which client should I use? - -Most modern Ruby client libraries for Google APIs come in two flavors: the main -client library with a name such as `google-cloud-gdc_hardware_management`, -and lower-level _versioned_ client libraries with names such as -`google-cloud-gdc_hardware_management-v1alpha`. -_In most cases, you should install the main client._ - -### What's the difference between the main client and a versioned client? - -A _versioned client_ provides a basic set of data types and client classes for -a _single version_ of a specific service. (That is, for a service with multiple -versions, there might be a separate versioned client for each service version.) -Most versioned clients are written and maintained by a code generator. - -The _main client_ is designed to provide you with the _recommended_ client -interfaces for the service. There will be only one main client for any given -service, even a service with multiple versions. The main client includes -factory methods for constructing the client objects we recommend for most -users. In some cases, those will be classes provided by an underlying versioned -client; in other cases, they will be handwritten higher-level client objects -with additional capabilities, convenience methods, or best practices built in. -Generally, the main client will default to a recommended service version, -although in some cases you can override this if you need to talk to a specific -service version. - -### Why would I want to use the main client? - -We recommend that most users install the main client gem for a service. You can -identify this gem as the one _without_ a version in its name, e.g. -`google-cloud-gdc_hardware_management`. -The main client is recommended because it will embody the best practices for -accessing the service, and may also provide more convenient interfaces or -tighter integration into frameworks and third-party libraries. In addition, the -documentation and samples published by Google will generally demonstrate use of -the main client. - -### Why would I want to use a versioned client? - -You can use a versioned client if you are content with a possibly lower-level -class interface, you explicitly want to avoid features provided by the main -client, or you want to access a specific service version not be covered by the -main client. You can identify versioned client gems because the service version -is part of the name, e.g. `google-cloud-gdc_hardware_management-v1alpha`. - -### What about the google-apis- clients? - -Client library gems with names that begin with `google-apis-` are based on an -older code generation technology. They talk to a REST/JSON backend (whereas -most modern clients talk to a [gRPC](https://grpc.io/) backend) and they may -not offer the same performance, features, and ease of use provided by more -modern clients. - -The `google-apis-` clients have wide coverage across Google services, so you -might need to use one if there is no modern client available for the service. -However, if a modern client is available, we generally recommend it over the -older `google-apis-` clients. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile deleted file mode 100644 index dd6a7f239d3d..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/Rakefile +++ /dev/null @@ -1,169 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "bundler/setup" -require "bundler/gem_tasks" - -require "rubocop/rake_task" -RuboCop::RakeTask.new - -require "rake/testtask" -desc "Run tests." -Rake::TestTask.new do |t| - t.libs << "test" - t.test_files = FileList["test/**/*_test.rb"] - t.warning = false -end - -desc "Runs the smoke tests." -Rake::TestTask.new :smoke_test do |t| - t.test_files = FileList["acceptance/**/*smoke_test.rb"] - t.warning = false -end - -# Acceptance tests -desc "Run the google-cloud-gdc_hardware_management-v1alpha acceptance tests." -task :acceptance, :project, :keyfile do |t, args| - project = args[:project] - project ||= - ENV["GOOGLE_CLOUD_TEST_PROJECT"] || - ENV["GCLOUD_TEST_PROJECT"] - keyfile = args[:keyfile] - keyfile ||= - ENV["GOOGLE_CLOUD_TEST_KEYFILE"] || - ENV["GCLOUD_TEST_KEYFILE"] - if keyfile - keyfile = File.read keyfile - else - keyfile ||= - ENV["GOOGLE_CLOUD_TEST_KEYFILE_JSON"] || - ENV["GCLOUD_TEST_KEYFILE_JSON"] - end - if project.nil? || keyfile.nil? - fail "You must provide a project and keyfile. e.g. rake acceptance[test123, /path/to/keyfile.json] or GOOGLE_CLOUD_TEST_PROJECT=test123 GOOGLE_CLOUD_TEST_KEYFILE=/path/to/keyfile.json rake acceptance" - end - require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Credentials.env_vars.each do |path| - ENV[path] = nil - end - ENV["GOOGLE_CLOUD_PROJECT"] = project - ENV["GOOGLE_CLOUD_TEST_PROJECT"] = project - ENV["GOOGLE_CLOUD_KEYFILE_JSON"] = keyfile - - Rake::Task["acceptance:run"].invoke -end - -namespace :acceptance do - task :run do - if File.directory? "acceptance" - Rake::Task[:smoke_test].invoke - else - puts "The google-cloud-gdc_hardware_management-v1alpha gem has no acceptance tests." - end - end - - desc "Run acceptance cleanup." - task :cleanup do - end -end - -task :samples do - Rake::Task["samples:latest"].invoke -end - -namespace :samples do - task :latest do - if File.directory? "samples" - Dir.chdir "samples" do - Bundler.with_clean_env do - ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "not_master" - sh "bundle update" - sh "bundle exec rake test" - end - end - else - puts "The google-cloud-gdc_hardware_management-v1alpha gem has no samples to test." - end - end - - task :master do - if File.directory? "samples" - Dir.chdir "samples" do - Bundler.with_clean_env do - ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "master" - sh "bundle update" - sh "bundle exec rake test" - end - end - else - puts "The google-cloud-gdc_hardware_management-v1alpha gem has no samples to test." - end - end -end - -require "yard" -require "yard/rake/yardoc_task" -YARD::Rake::YardocTask.new do |y| - y.options << "--fail-on-warning" -end - -desc "Run yard-doctest example tests." -task :doctest do - puts "The google-cloud-gdc_hardware_management-v1alpha gem does not have doctest tests." -end - -desc "Run the CI build" -task :ci do - header "BUILDING google-cloud-gdc_hardware_management-v1alpha" - header "google-cloud-gdc_hardware_management-v1alpha rubocop", "*" - Rake::Task[:rubocop].invoke - header "google-cloud-gdc_hardware_management-v1alpha yard", "*" - Rake::Task[:yard].invoke - header "google-cloud-gdc_hardware_management-v1alpha test", "*" - Rake::Task[:test].invoke -end - -namespace :ci do - desc "Run the CI build, with smoke tests." - task :smoke_test do - Rake::Task[:ci].invoke - header "google-cloud-gdc_hardware_management-v1alpha smoke_test", "*" - Rake::Task[:smoke_test].invoke - end - desc "Run the CI build, with acceptance tests." - task :acceptance do - Rake::Task[:ci].invoke - header "google-cloud-gdc_hardware_management-v1alpha acceptance", "*" - Rake::Task[:acceptance].invoke - end - task :a do - # This is a handy shortcut to save typing - Rake::Task["ci:acceptance"].invoke - end -end - -task default: :test - -def header str, token = "#" - line_length = str.length + 8 - puts "" - puts token * line_length - puts "#{token * 3} #{str} #{token * 3}" - puts token * line_length - puts "" -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json deleted file mode 100644 index 87a29abf2b0e..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/gapic_metadata.json +++ /dev/null @@ -1,203 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", - "language": "ruby", - "protoPackage": "google.cloud.gdchardwaremanagement.v1alpha", - "libraryPackage": "::Google::Cloud::GDCHardwareManagement::V1alpha", - "services": { - "GDCHardwareManagement": { - "clients": { - "grpc": { - "libraryClient": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client", - "rpcs": { - "ListOrders": { - "methods": [ - "list_orders" - ] - }, - "GetOrder": { - "methods": [ - "get_order" - ] - }, - "CreateOrder": { - "methods": [ - "create_order" - ] - }, - "UpdateOrder": { - "methods": [ - "update_order" - ] - }, - "DeleteOrder": { - "methods": [ - "delete_order" - ] - }, - "SubmitOrder": { - "methods": [ - "submit_order" - ] - }, - "CancelOrder": { - "methods": [ - "cancel_order" - ] - }, - "ListSites": { - "methods": [ - "list_sites" - ] - }, - "GetSite": { - "methods": [ - "get_site" - ] - }, - "CreateSite": { - "methods": [ - "create_site" - ] - }, - "UpdateSite": { - "methods": [ - "update_site" - ] - }, - "DeleteSite": { - "methods": [ - "delete_site" - ] - }, - "ListHardwareGroups": { - "methods": [ - "list_hardware_groups" - ] - }, - "GetHardwareGroup": { - "methods": [ - "get_hardware_group" - ] - }, - "CreateHardwareGroup": { - "methods": [ - "create_hardware_group" - ] - }, - "UpdateHardwareGroup": { - "methods": [ - "update_hardware_group" - ] - }, - "DeleteHardwareGroup": { - "methods": [ - "delete_hardware_group" - ] - }, - "ListHardware": { - "methods": [ - "list_hardware" - ] - }, - "GetHardware": { - "methods": [ - "get_hardware" - ] - }, - "CreateHardware": { - "methods": [ - "create_hardware" - ] - }, - "UpdateHardware": { - "methods": [ - "update_hardware" - ] - }, - "DeleteHardware": { - "methods": [ - "delete_hardware" - ] - }, - "ListComments": { - "methods": [ - "list_comments" - ] - }, - "GetComment": { - "methods": [ - "get_comment" - ] - }, - "CreateComment": { - "methods": [ - "create_comment" - ] - }, - "RecordActionOnComment": { - "methods": [ - "record_action_on_comment" - ] - }, - "ListChangeLogEntries": { - "methods": [ - "list_change_log_entries" - ] - }, - "GetChangeLogEntry": { - "methods": [ - "get_change_log_entry" - ] - }, - "ListSkus": { - "methods": [ - "list_skus" - ] - }, - "GetSku": { - "methods": [ - "get_sku" - ] - }, - "ListZones": { - "methods": [ - "list_zones" - ] - }, - "GetZone": { - "methods": [ - "get_zone" - ] - }, - "CreateZone": { - "methods": [ - "create_zone" - ] - }, - "UpdateZone": { - "methods": [ - "update_zone" - ] - }, - "DeleteZone": { - "methods": [ - "delete_zone" - ] - }, - "SignalZoneState": { - "methods": [ - "signal_zone_state" - ] - }, - "RequestOrderDateChange": { - "methods": [ - "request_order_date_change" - ] - } - } - } - } - } - } -} diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec deleted file mode 100644 index fa8f96ea06dc..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/google-cloud-gdc_hardware_management-v1alpha.gemspec +++ /dev/null @@ -1,29 +0,0 @@ -# -*- ruby -*- -# encoding: utf-8 - -require File.expand_path("lib/google/cloud/gdc_hardware_management/v1alpha/version", __dir__) - -Gem::Specification.new do |gem| - gem.name = "google-cloud-gdc_hardware_management-v1alpha" - gem.version = Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - - gem.authors = ["Google LLC"] - gem.email = "googleapis-packages@google.com" - gem.description = "google-cloud-gdc_hardware_management-v1alpha is the official client library for the GDC Hardware Management V1ALPHA API. Note that google-cloud-gdc_hardware_management-v1alpha is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-gdc_hardware_management instead. See the readme for more details." - gem.summary = "API Client library for the GDC Hardware Management V1ALPHA API" - gem.homepage = "https://github.com/googleapis/google-cloud-ruby" - gem.license = "Apache-2.0" - - gem.platform = Gem::Platform::RUBY - - gem.files = `git ls-files -- lib/*`.split("\n") + - `git ls-files -- proto_docs/*`.split("\n") + - ["README.md", "LICENSE.md", "AUTHENTICATION.md", ".yardopts"] - gem.require_paths = ["lib"] - - gem.required_ruby_version = ">= 3.1" - - gem.add_dependency "gapic-common", "~> 1.2" - gem.add_dependency "google-cloud-errors", "~> 1.0" - gem.add_dependency "google-cloud-location", "~> 1.0" -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb deleted file mode 100644 index d40020ca9852..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google-cloud-gdc_hardware_management-v1alpha.rb +++ /dev/null @@ -1,21 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# This gem does not autoload during Bundler.require. To load this gem, -# issue explicit require statements for the packages desired, e.g.: -# require "google/cloud/gdc_hardware_management/v1alpha" diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb deleted file mode 100644 index 6db51170738a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha.rb +++ /dev/null @@ -1,45 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" -require "google/cloud/gdc_hardware_management/v1alpha/version" - -module Google - module Cloud - module GDCHardwareManagement - ## - # API client module. - # - # @example Load this package, including all its services, and instantiate a gRPC client - # - # require "google/cloud/gdc_hardware_management/v1alpha" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # @example Load this package, including all its services, and instantiate a REST client - # - # require "google/cloud/gdc_hardware_management/v1alpha" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - module V1alpha - end - end - end -end - -helper_path = ::File.join __dir__, "v1alpha", "_helpers.rb" -require "google/cloud/gdc_hardware_management/v1alpha/_helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb deleted file mode 100644 index d13989b04895..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/bindings_override.rb +++ /dev/null @@ -1,75 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "gapic/rest" - -module Google - module Cloud - module GDCHardwareManagement - ## - # @example Loading just the REST part of this package, including all its services, and instantiating a REST client - # - # require "google/cloud/gdc_hardware_management/v1alpha/rest" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - module V1alpha - ## - # @private - # Initialize the mixin bindings configuration - # - def self.configure - @configure ||= begin - namespace = ["Google", "Cloud", "GDCHardwareManagement"] - parent_config = while namespace.any? - parent_name = namespace.join "::" - parent_const = const_get parent_name - break parent_const.configure if parent_const.respond_to? :configure - namespace.pop - end - - default_config = ::Gapic::Rest::HttpBindingOverrideConfiguration.new parent_config - default_config.bindings_override["google.cloud.location.Locations.GetLocation"] = [ - Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ], - body: nil - ) - ] - default_config.bindings_override["google.cloud.location.Locations.ListLocations"] = [ - - Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( - uri_method: :get, - uri_template: "/v1alpha/{name}/locations", - matches: [ - ["name", %r{^projects/[^/]+/?$}, false] - ], - body: nil - ) - ] - default_config - end - yield @configure if block_given? - @configure - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb deleted file mode 100644 index 954c647498da..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management.rb +++ /dev/null @@ -1,56 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "gapic/common" -require "gapic/config" -require "gapic/config/method" - -require "google/cloud/gdc_hardware_management/v1alpha/version" - -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - ## - # The GDC Hardware Management service. - # - # @example Load this service and instantiate a gRPC client - # - # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # @example Load this service and instantiate a REST client - # - # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - module GDCHardwareManagement - end - end - end - end -end - -helper_path = ::File.join __dir__, "gdc_hardware_management", "helpers.rb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb deleted file mode 100644 index aa86199e8d7b..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/client.rb +++ /dev/null @@ -1,4499 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "google/cloud/errors" -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" -require "google/cloud/location" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - ## - # Client for the GDCHardwareManagement service. - # - # The GDC Hardware Management service. - # - class Client - # @private - API_VERSION = "" - - # @private - DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" - - include Paths - - # @private - attr_reader :gdc_hardware_management_stub - - ## - # Configure the GDCHardwareManagement Client class. - # - # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration} - # for a description of the configuration fields. - # - # @example - # - # # Modify the configuration for all GDCHardwareManagement clients - # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| - # config.timeout = 10.0 - # end - # - # @yield [config] Configure the Client client. - # @yieldparam config [Client::Configuration] - # - # @return [Client::Configuration] - # - def self.configure - @configure ||= begin - namespace = ["Google", "Cloud", "GDCHardwareManagement", "V1alpha"] - parent_config = while namespace.any? - parent_name = namespace.join "::" - parent_const = const_get parent_name - break parent_const.configure if parent_const.respond_to? :configure - namespace.pop - end - default_config = Client::Configuration.new parent_config - - default_config.rpcs.list_orders.timeout = 60.0 - default_config.rpcs.list_orders.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_order.timeout = 60.0 - default_config.rpcs.get_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_order.timeout = 60.0 - - default_config.rpcs.update_order.timeout = 60.0 - default_config.rpcs.update_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_order.timeout = 60.0 - default_config.rpcs.delete_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.submit_order.timeout = 60.0 - default_config.rpcs.submit_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.cancel_order.timeout = 60.0 - default_config.rpcs.cancel_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_sites.timeout = 60.0 - default_config.rpcs.list_sites.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_site.timeout = 60.0 - default_config.rpcs.get_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_site.timeout = 60.0 - - default_config.rpcs.update_site.timeout = 60.0 - default_config.rpcs.update_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_site.timeout = 60.0 - default_config.rpcs.delete_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_hardware_groups.timeout = 60.0 - default_config.rpcs.list_hardware_groups.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_hardware_group.timeout = 60.0 - default_config.rpcs.get_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_hardware_group.timeout = 60.0 - - default_config.rpcs.update_hardware_group.timeout = 60.0 - default_config.rpcs.update_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_hardware_group.timeout = 60.0 - default_config.rpcs.delete_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_hardware.timeout = 60.0 - default_config.rpcs.list_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_hardware.timeout = 60.0 - default_config.rpcs.get_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_hardware.timeout = 60.0 - - default_config.rpcs.update_hardware.timeout = 60.0 - default_config.rpcs.update_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_hardware.timeout = 60.0 - default_config.rpcs.delete_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_comments.timeout = 60.0 - default_config.rpcs.list_comments.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_comment.timeout = 60.0 - default_config.rpcs.get_comment.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_comment.timeout = 60.0 - - default_config.rpcs.list_change_log_entries.timeout = 60.0 - default_config.rpcs.list_change_log_entries.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_change_log_entry.timeout = 60.0 - default_config.rpcs.get_change_log_entry.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_skus.timeout = 60.0 - default_config.rpcs.list_skus.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_sku.timeout = 60.0 - default_config.rpcs.get_sku.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_zones.timeout = 60.0 - default_config.rpcs.list_zones.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_zone.timeout = 60.0 - default_config.rpcs.get_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_zone.timeout = 60.0 - - default_config.rpcs.update_zone.timeout = 60.0 - default_config.rpcs.update_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_zone.timeout = 60.0 - default_config.rpcs.delete_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config - end - yield @configure if block_given? - @configure - end - - ## - # Configure the GDCHardwareManagement Client instance. - # - # The configuration is set to the derived mode, meaning that values can be changed, - # but structural changes (adding new fields, etc.) are not allowed. Structural changes - # should be made on {Client.configure}. - # - # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration} - # for a description of the configuration fields. - # - # @yield [config] Configure the Client client. - # @yieldparam config [Client::Configuration] - # - # @return [Client::Configuration] - # - def configure - yield @config if block_given? - @config - end - - ## - # The effective universe domain - # - # @return [String] - # - def universe_domain - @gdc_hardware_management_stub.universe_domain - end - - ## - # Create a new GDCHardwareManagement client object. - # - # @example - # - # # Create a client using the default configuration - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a client using a custom configuration - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - # config.timeout = 10.0 - # end - # - # @yield [config] Configure the GDCHardwareManagement client. - # @yieldparam config [Client::Configuration] - # - def initialize - # These require statements are intentionally placed here to initialize - # the gRPC module only when it's required. - # See https://github.com/googleapis/toolkit/issues/446 - require "gapic/grpc" - require "google/cloud/gdchardwaremanagement/v1alpha/service_services_pb" - - # Create the configuration object - @config = Configuration.new Client.configure - - # Yield the configuration if needed - yield @config if block_given? - - # Create credentials - credentials = @config.credentials - # Use self-signed JWT if the endpoint is unchanged from default, - # but only if the default endpoint does not have a region prefix. - enable_self_signed_jwt = @config.endpoint.nil? || - (@config.endpoint == Configuration::DEFAULT_ENDPOINT && - !@config.endpoint.split(".").first.include?("-")) - credentials ||= Credentials.default scope: @config.scope, - enable_self_signed_jwt: enable_self_signed_jwt - if credentials.is_a?(::String) || credentials.is_a?(::Hash) - credentials = Credentials.new credentials, scope: @config.scope - end - @quota_project_id = @config.quota_project - @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id - - @operations_client = Operations.new do |config| - config.credentials = credentials - config.quota_project = @quota_project_id - config.endpoint = @config.endpoint - config.universe_domain = @config.universe_domain - end - - @gdc_hardware_management_stub = ::Gapic::ServiceStub.new( - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Stub, - credentials: credentials, - endpoint: @config.endpoint, - endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, - universe_domain: @config.universe_domain, - channel_args: @config.channel_args, - interceptors: @config.interceptors, - channel_pool_config: @config.channel_pool, - logger: @config.logger - ) - - @gdc_hardware_management_stub.stub_logger&.info do |entry| - entry.set_system_name - entry.set_service - entry.message = "Created client for #{entry.service}" - entry.set_credentials_fields credentials - entry.set "customEndpoint", @config.endpoint if @config.endpoint - entry.set "defaultTimeout", @config.timeout if @config.timeout - entry.set "quotaProject", @quota_project_id if @quota_project_id - end - - @location_client = Google::Cloud::Location::Locations::Client.new do |config| - config.credentials = credentials - config.quota_project = @quota_project_id - config.endpoint = @gdc_hardware_management_stub.endpoint - config.universe_domain = @gdc_hardware_management_stub.universe_domain - config.logger = @gdc_hardware_management_stub.logger if config.respond_to? :logger= - end - end - - ## - # Get the associated client for long-running operations. - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations] - # - attr_reader :operations_client - - ## - # Get the associated client for mix-in of the Locations. - # - # @return [Google::Cloud::Location::Locations::Client] - # - attr_reader :location_client - - ## - # The logger used for request/response debug logging. - # - # @return [Logger] - # - def logger - @gdc_hardware_management_stub.logger - end - - # Service calls - - ## - # Lists orders in a given project and location. - # - # @overload list_orders(request, options = nil) - # Pass arguments to `list_orders` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_orders(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_orders` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list orders in. - # Format: `projects/{project}/locations/{location}` - # - # To list orders across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new - # - # # Call the list_orders method. - # result = client.list_orders request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. - # p item - # end - # - def list_orders request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_orders.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_orders.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_orders.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_orders, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_orders, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of an order. - # - # @overload get_order(request, options = nil) - # Pass arguments to `get_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_order(name: nil) - # Pass arguments to `get_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. Name of the resource - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new - # - # # Call the get_order method. - # result = client.get_order request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. - # p result - # - def get_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_order, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new order in a given project and location. - # - # @overload create_order(request, options = nil) - # Pass arguments to `create_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_order(parent: nil, order_id: nil, order: nil, request_id: nil) - # Pass arguments to `create_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the order in. - # Format: `projects/{project}/locations/{location}` - # @param order_id [::String] - # Optional. ID used to uniquely identify the Order within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The order.name field in the request will be ignored. - # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] - # Required. The order to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new - # - # # Call the create_order method. - # result = client.create_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_order, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of an order. - # - # @overload update_order(request, options = nil) - # Pass arguments to `update_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload update_order(update_mask: nil, order: nil, request_id: nil) - # Pass arguments to `update_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Order to overwrite with this - # update. The fields specified in the update_mask are relative to the order, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] - # Required. The order to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new - # - # # Call the update_order method. - # result = client.update_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.update_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.order&.name - header_params["order.name"] = request.order.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.update_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.update_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :update_order, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes an order. - # - # @overload delete_order(request, options = nil) - # Pass arguments to `delete_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_order(name: nil, request_id: nil, force: nil) - # Pass arguments to `delete_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param force [::Boolean] - # Optional. An option to delete any nested resources in the Order, such as a - # HardwareGroup. If true, any nested resources for this Order will also be - # deleted. Otherwise, the request will only succeed if the Order has no - # nested resources. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new - # - # # Call the delete_order method. - # result = client.delete_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :delete_order, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Submits an order. - # - # @overload submit_order(request, options = nil) - # Pass arguments to `submit_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload submit_order(name: nil, request_id: nil, type: nil) - # Pass arguments to `submit_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param type [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] - # Optional. Type of this request. If unset, the request type is assumed to be - # `INFO_PENDING`. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new - # - # # Call the submit_order method. - # result = client.submit_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def submit_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.submit_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.submit_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.submit_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :submit_order, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Cancels an order. - # - # @overload cancel_order(request, options = nil) - # Pass arguments to `cancel_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload cancel_order(name: nil, request_id: nil) - # Pass arguments to `cancel_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new - # - # # Call the cancel_order method. - # result = client.cancel_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def cancel_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.cancel_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.cancel_order.timeout, - metadata: metadata, - retry_policy: @config.rpcs.cancel_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :cancel_order, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists sites in a given project and location. - # - # @overload list_sites(request, options = nil) - # Pass arguments to `list_sites` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_sites(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_sites` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list sites in. - # Format: `projects/{project}/locations/{location}` - # - # To list sites across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new - # - # # Call the list_sites method. - # result = client.list_sites request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. - # p item - # end - # - def list_sites request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_sites.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_sites.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_sites.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_sites, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_sites, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a site. - # - # @overload get_site(request, options = nil) - # Pass arguments to `get_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_site(name: nil) - # Pass arguments to `get_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new - # - # # Call the get_site method. - # result = client.get_site request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. - # p result - # - def get_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_site.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_site, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new site in a given project and location. - # - # @overload create_site(request, options = nil) - # Pass arguments to `create_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_site(parent: nil, site_id: nil, site: nil, request_id: nil) - # Pass arguments to `create_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the site in. - # Format: `projects/{project}/locations/{location}` - # @param site_id [::String] - # Optional. ID used to uniquely identify the Site within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The site.name field in the request will be ignored. - # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] - # Required. The site to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new - # - # # Call the create_site method. - # result = client.create_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_site.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_site, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a site. - # - # @overload update_site(request, options = nil) - # Pass arguments to `update_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload update_site(update_mask: nil, site: nil, request_id: nil) - # Pass arguments to `update_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Site to overwrite with this - # update. The fields specified in the update_mask are relative to the site, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] - # Required. The site to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new - # - # # Call the update_site method. - # result = client.update_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.update_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.site&.name - header_params["site.name"] = request.site.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.update_site.timeout, - metadata: metadata, - retry_policy: @config.rpcs.update_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :update_site, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a site. - # - # @overload delete_site(request, options = nil) - # Pass arguments to `delete_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_site(name: nil, request_id: nil) - # Pass arguments to `delete_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new - # - # # Call the delete_site method. - # result = client.delete_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_site.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :delete_site, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists hardware groups in a given order. - # - # @overload list_hardware_groups(request, options = nil) - # Pass arguments to `list_hardware_groups` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_hardware_groups(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_hardware_groups` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list hardware groups in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new - # - # # Call the list_hardware_groups method. - # result = client.list_hardware_groups request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - # p item - # end - # - def list_hardware_groups request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_hardware_groups.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_hardware_groups.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_hardware_groups.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_hardware_groups, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware_groups, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a hardware group. - # - # @overload get_hardware_group(request, options = nil) - # Pass arguments to `get_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_hardware_group(name: nil) - # Pass arguments to `get_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new - # - # # Call the get_hardware_group method. - # result = client.get_hardware_group request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - # p result - # - def get_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_hardware_group.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_hardware_group, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new hardware group in a given order. - # - # @overload create_hardware_group(request, options = nil) - # Pass arguments to `create_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_hardware_group(parent: nil, hardware_group_id: nil, hardware_group: nil, request_id: nil) - # Pass arguments to `create_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to create the hardware group in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param hardware_group_id [::String] - # Optional. ID used to uniquely identify the HardwareGroup within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware_group.name field in the request will be ignored. - # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] - # Required. The hardware group to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new - # - # # Call the create_hardware_group method. - # result = client.create_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_hardware_group.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_hardware_group, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a hardware group. - # - # @overload update_hardware_group(request, options = nil) - # Pass arguments to `update_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload update_hardware_group(update_mask: nil, hardware_group: nil, request_id: nil) - # Pass arguments to `update_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the HardwareGroup to overwrite - # with this update. The fields specified in the update_mask are relative to - # the hardware group, not the full request. A field will be overwritten if it - # is in the mask. If you don't provide a mask then all fields will be - # overwritten. - # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] - # Required. The hardware group to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new - # - # # Call the update_hardware_group method. - # result = client.update_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.update_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.hardware_group&.name - header_params["hardware_group.name"] = request.hardware_group.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.update_hardware_group.timeout, - metadata: metadata, - retry_policy: @config.rpcs.update_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :update_hardware_group, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a hardware group. - # - # @overload delete_hardware_group(request, options = nil) - # Pass arguments to `delete_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_hardware_group(name: nil, request_id: nil) - # Pass arguments to `delete_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new - # - # # Call the delete_hardware_group method. - # result = client.delete_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_hardware_group.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :delete_hardware_group, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists hardware in a given project and location. - # - # @overload list_hardware(request, options = nil) - # Pass arguments to `list_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_hardware(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list hardware in. - # Format: `projects/{project}/locations/{location}` - # - # To list hardware across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new - # - # # Call the list_hardware method. - # result = client.list_hardware request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - # p item - # end - # - def list_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_hardware.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_hardware, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets hardware details. - # - # @overload get_hardware(request, options = nil) - # Pass arguments to `get_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_hardware(name: nil) - # Pass arguments to `get_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new - # - # # Call the get_hardware method. - # result = client.get_hardware request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - # p result - # - def get_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_hardware.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_hardware, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates new hardware in a given project and location. - # - # @overload create_hardware(request, options = nil) - # Pass arguments to `create_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_hardware(parent: nil, hardware_id: nil, hardware: nil) - # Pass arguments to `create_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create hardware in. - # Format: `projects/{project}/locations/{location}` - # @param hardware_id [::String] - # Optional. ID used to uniquely identify the Hardware within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware.name field in the request will be ignored. - # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] - # Required. The resource to create. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new - # - # # Call the create_hardware method. - # result = client.create_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_hardware.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_hardware, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates hardware parameters. - # - # @overload update_hardware(request, options = nil) - # Pass arguments to `update_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload update_hardware(update_mask: nil, hardware: nil, request_id: nil) - # Pass arguments to `update_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Hardware to overwrite with - # this update. The fields specified in the update_mask are relative to the - # hardware, not the full request. A field will be overwritten if it is in the - # mask. If you don't provide a mask then all fields will be overwritten. - # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] - # Required. The hardware to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new - # - # # Call the update_hardware method. - # result = client.update_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.update_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.hardware&.name - header_params["hardware.name"] = request.hardware.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.update_hardware.timeout, - metadata: metadata, - retry_policy: @config.rpcs.update_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :update_hardware, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes hardware. - # - # @overload delete_hardware(request, options = nil) - # Pass arguments to `delete_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_hardware(name: nil, request_id: nil) - # Pass arguments to `delete_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new - # - # # Call the delete_hardware method. - # result = client.delete_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_hardware.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :delete_hardware, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists the comments on an order. - # - # @overload list_comments(request, options = nil) - # Pass arguments to `list_comments` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_comments(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_comments` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list comments on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new - # - # # Call the list_comments method. - # result = client.list_comments request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p item - # end - # - def list_comments request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_comments.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_comments.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_comments.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_comments, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_comments, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets the content of a comment. - # - # @overload get_comment(request, options = nil) - # Pass arguments to `get_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_comment(name: nil) - # Pass arguments to `get_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new - # - # # Call the get_comment method. - # result = client.get_comment request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p result - # - def get_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_comment.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_comment, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new comment on an order. - # - # @overload create_comment(request, options = nil) - # Pass arguments to `create_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_comment(parent: nil, comment_id: nil, comment: nil, request_id: nil) - # Pass arguments to `create_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to create the comment on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param comment_id [::String] - # Optional. ID used to uniquely identify the Comment within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The comment.name field in the request will be ignored. - # @param comment [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment, ::Hash] - # Required. The comment to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new - # - # # Call the create_comment method. - # result = client.create_comment request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_comment.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_comment, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Record Action on a Comment. If the Action specified in the request is READ, - # the viewed time in the comment is set to the time the request was received. - # If the comment is already marked as read, subsequent calls will be ignored. - # If the Action is UNREAD, the viewed time is cleared from the comment. - # - # @overload record_action_on_comment(request, options = nil) - # Pass arguments to `record_action_on_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload record_action_on_comment(name: nil, action_type: nil) - # Pass arguments to `record_action_on_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # @param action_type [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] - # Required. The action type of the recorded action. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new - # - # # Call the record_action_on_comment method. - # result = client.record_action_on_comment request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p result - # - def record_action_on_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.record_action_on_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.record_action_on_comment.timeout, - metadata: metadata, - retry_policy: @config.rpcs.record_action_on_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :record_action_on_comment, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists the changes made to an order. - # - # @overload list_change_log_entries(request, options = nil) - # Pass arguments to `list_change_log_entries` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_change_log_entries(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_change_log_entries` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list change log entries for. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new - # - # # Call the list_change_log_entries method. - # result = client.list_change_log_entries request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - # p item - # end - # - def list_change_log_entries request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_change_log_entries.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_change_log_entries.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_change_log_entries.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_change_log_entries, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_change_log_entries, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a change to an order. - # - # @overload get_change_log_entry(request, options = nil) - # Pass arguments to `get_change_log_entry` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_change_log_entry(name: nil) - # Pass arguments to `get_change_log_entry` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the change log entry. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new - # - # # Call the get_change_log_entry method. - # result = client.get_change_log_entry request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - # p result - # - def get_change_log_entry request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_change_log_entry.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_change_log_entry.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_change_log_entry.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_change_log_entry, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists SKUs for a given project and location. - # - # @overload list_skus(request, options = nil) - # Pass arguments to `list_skus` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_skus(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_skus` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list SKUs in. - # Format: `projects/{project}/locations/{location}` - # - # To list SKUs across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new - # - # # Call the list_skus method. - # result = client.list_skus request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - # p item - # end - # - def list_skus request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_skus.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_skus.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_skus.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_skus, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_skus, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of an SKU. - # - # @overload get_sku(request, options = nil) - # Pass arguments to `get_sku` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_sku(name: nil) - # Pass arguments to `get_sku` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the SKU. - # Format: `projects/{project}/locations/{location}/skus/{sku}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new - # - # # Call the get_sku method. - # result = client.get_sku request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - # p result - # - def get_sku request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_sku.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_sku.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_sku.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_sku, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists zones in a given project and location. - # - # @overload list_zones(request, options = nil) - # Pass arguments to `list_zones` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_zones(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_zones` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list zones in. - # Format: `projects/{project}/locations/{location}` - # - # To list zones across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new - # - # # Call the list_zones method. - # result = client.list_zones request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - # p item - # end - # - def list_zones request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_zones.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_zones.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_zones.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :list_zones, request, options: options do |response, operation| - response = ::Gapic::PagedEnumerable.new @gdc_hardware_management_stub, :list_zones, request, response, operation, options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a zone. - # - # @overload get_zone(request, options = nil) - # Pass arguments to `get_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_zone(name: nil) - # Pass arguments to `get_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new - # - # # Call the get_zone method. - # result = client.get_zone request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - # p result - # - def get_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_zone.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :get_zone, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new zone in a given project and location. - # - # @overload create_zone(request, options = nil) - # Pass arguments to `create_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload create_zone(parent: nil, zone_id: nil, zone: nil, request_id: nil) - # Pass arguments to `create_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the zone in. - # Format: `projects/{project}/locations/{location}` - # @param zone_id [::String] - # Optional. ID used to uniquely identify the Zone within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The zone.name field in the request will be ignored. - # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] - # Required. The zone to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new - # - # # Call the create_zone method. - # result = client.create_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.create_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.parent - header_params["parent"] = request.parent - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.create_zone.timeout, - metadata: metadata, - retry_policy: @config.rpcs.create_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :create_zone, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a zone. - # - # @overload update_zone(request, options = nil) - # Pass arguments to `update_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload update_zone(update_mask: nil, zone: nil, request_id: nil) - # Pass arguments to `update_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Zone to overwrite with this - # update. The fields specified in the update_mask are relative to the zone, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] - # Required. The zone to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new - # - # # Call the update_zone method. - # result = client.update_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.update_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.zone&.name - header_params["zone.name"] = request.zone.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.update_zone.timeout, - metadata: metadata, - retry_policy: @config.rpcs.update_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :update_zone, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a zone. - # - # @overload delete_zone(request, options = nil) - # Pass arguments to `delete_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_zone(name: nil, request_id: nil) - # Pass arguments to `delete_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new - # - # # Call the delete_zone method. - # result = client.delete_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_zone.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :delete_zone, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Signals the state of a zone. - # - # @overload signal_zone_state(request, options = nil) - # Pass arguments to `signal_zone_state` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload signal_zone_state(name: nil, request_id: nil, state_signal: nil, provisioning_state_signal: nil, step: nil, details: nil) - # Pass arguments to `signal_zone_state` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] - # Optional. The state signal to send for this zone. Either state_signal or - # provisioning_state_signal must be set, but not both. - # @param provisioning_state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] - # Optional. The provisioning state signal to send for this zone. Either - # state_signal or provisioning_state_signal must be set, but not both. - # @param step [::String] - # Optional. The step being executed. Provides a finer grained status when the - # state_signal is FACTORY_TURNUP_CHECKS_STARTED or - # FACTORY_TURNUP_CHECKS_FAILED. - # @param details [::String] - # Optional. Additional details, such as an error message when state_signal is - # FACTORY_TURNUP_CHECKS_FAILED. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new - # - # # Call the signal_zone_state method. - # result = client.signal_zone_state request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def signal_zone_state request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.signal_zone_state.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.signal_zone_state.timeout, - metadata: metadata, - retry_policy: @config.rpcs.signal_zone_state.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :signal_zone_state, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the requested date change of a single Order. - # - # @overload request_order_date_change(request, options = nil) - # Pass arguments to `request_order_date_change` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload request_order_date_change(name: nil, requested_date: nil) - # Pass arguments to `request_order_date_change` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order to update. - # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} - # @param requested_date [::Google::Type::Date, ::Hash] - # Required. The date to which the customer or Google wants to set the - # scheduled installation date. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new - # - # # Call the request_order_date_change method. - # result = client.request_order_date_change request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def request_order_date_change request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.request_order_date_change.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.request_order_date_change.timeout, - metadata: metadata, - retry_policy: @config.rpcs.request_order_date_change.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.call_rpc :request_order_date_change, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Configuration class for the GDCHardwareManagement API. - # - # This class represents the configuration for GDCHardwareManagement, - # providing control over timeouts, retry behavior, logging, transport - # parameters, and other low-level controls. Certain parameters can also be - # applied individually to specific RPCs. See - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration::Rpcs} - # for a list of RPCs that can be configured independently. - # - # Configuration can be applied globally to all clients, or to a single client - # on construction. - # - # @example - # - # # Modify the global config, setting the timeout for - # # list_orders to 20 seconds, - # # and all remaining timeouts to 10 seconds. - # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.configure do |config| - # config.timeout = 10.0 - # config.rpcs.list_orders.timeout = 20.0 - # end - # - # # Apply the above configuration only to a new client. - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - # config.timeout = 10.0 - # config.rpcs.list_orders.timeout = 20.0 - # end - # - # @!attribute [rw] endpoint - # A custom service endpoint, as a hostname or hostname:port. The default is - # nil, indicating to use the default endpoint in the current universe domain. - # @return [::String,nil] - # @!attribute [rw] credentials - # Credentials to send with calls. You may provide any of the following types: - # * (`Google::Auth::Credentials`) A googleauth credentials object - # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) - # * (`Signet::OAuth2::Client`) A signet oauth2 client object - # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) - # * (`GRPC::Core::Channel`) a gRPC channel with included credentials - # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object - # * (`nil`) indicating no credentials - # - # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials - # is deprecated. Providing an unvalidated credential configuration to - # Google APIs can compromise the security of your systems and data. - # - # @example - # - # # The recommended way to provide credentials is to use the `make_creds` method - # # on the appropriate credentials class for your environment. - # - # require "googleauth" - # - # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds( - # json_key_io: ::File.open("/path/to/keyfile.json") - # ) - # - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - # config.credentials = credentials - # end - # - # @note Warning: If you accept a credential configuration (JSON file or Hash) from an - # external source for authentication to Google Cloud, you must validate it before - # providing it to a Google API client library. Providing an unvalidated credential - # configuration to Google APIs can compromise the security of your systems and data. - # For more information, refer to [Validate credential configurations from external - # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). - # @return [::Object] - # @!attribute [rw] scope - # The OAuth scopes - # @return [::Array<::String>] - # @!attribute [rw] lib_name - # The library name as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] lib_version - # The library version as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] channel_args - # Extra parameters passed to the gRPC channel. Note: this is ignored if a - # `GRPC::Core::Channel` object is provided as the credential. - # @return [::Hash] - # @!attribute [rw] interceptors - # An array of interceptors that are run before calls are executed. - # @return [::Array<::GRPC::ClientInterceptor>] - # @!attribute [rw] timeout - # The call timeout in seconds. - # @return [::Numeric] - # @!attribute [rw] metadata - # Additional gRPC headers to be sent with the call. - # @return [::Hash{::Symbol=>::String}] - # @!attribute [rw] retry_policy - # The retry policy. The value is a hash with the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # @return [::Hash] - # @!attribute [rw] quota_project - # A separate project against which to charge quota. - # @return [::String] - # @!attribute [rw] universe_domain - # The universe domain within which to make requests. This determines the - # default endpoint URL. The default value of nil uses the environment - # universe (usually the default "googleapis.com" universe). - # @return [::String,nil] - # @!attribute [rw] logger - # A custom logger to use for request/response debug logging, or the value - # `:default` (the default) to construct a default logger, or `nil` to - # explicitly disable logging. - # @return [::Logger,:default,nil] - # - class Configuration - extend ::Gapic::Config - - # @private - # The endpoint specific to the default "googleapis.com" universe. Deprecated. - DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" - - config_attr :endpoint, nil, ::String, nil - config_attr :credentials, nil do |value| - allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] - allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC::Core::Channel - allowed.any? { |klass| klass === value } - end - config_attr :scope, nil, ::String, ::Array, nil - config_attr :lib_name, nil, ::String, nil - config_attr :lib_version, nil, ::String, nil - config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil) - config_attr :interceptors, nil, ::Array, nil - config_attr :timeout, nil, ::Numeric, nil - config_attr :metadata, nil, ::Hash, nil - config_attr :retry_policy, nil, ::Hash, ::Proc, nil - config_attr :quota_project, nil, ::String, nil - config_attr :universe_domain, nil, ::String, nil - config_attr :logger, :default, ::Logger, nil, :default - - # @private - def initialize parent_config = nil - @parent_config = parent_config unless parent_config.nil? - - yield self if block_given? - end - - ## - # Configurations for individual RPCs - # @return [Rpcs] - # - def rpcs - @rpcs ||= begin - parent_rpcs = nil - parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) - Rpcs.new parent_rpcs - end - end - - ## - # Configuration for the channel pool - # @return [::Gapic::ServiceStub::ChannelPool::Configuration] - # - def channel_pool - @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new - end - - ## - # Configuration RPC class for the GDCHardwareManagement API. - # - # Includes fields providing the configuration for each RPC in this service. - # Each configuration object is of type `Gapic::Config::Method` and includes - # the following configuration fields: - # - # * `timeout` (*type:* `Numeric`) - The call timeout in seconds - # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers - # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields - # include the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # - class Rpcs - ## - # RPC-specific configuration for `list_orders` - # @return [::Gapic::Config::Method] - # - attr_reader :list_orders - ## - # RPC-specific configuration for `get_order` - # @return [::Gapic::Config::Method] - # - attr_reader :get_order - ## - # RPC-specific configuration for `create_order` - # @return [::Gapic::Config::Method] - # - attr_reader :create_order - ## - # RPC-specific configuration for `update_order` - # @return [::Gapic::Config::Method] - # - attr_reader :update_order - ## - # RPC-specific configuration for `delete_order` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_order - ## - # RPC-specific configuration for `submit_order` - # @return [::Gapic::Config::Method] - # - attr_reader :submit_order - ## - # RPC-specific configuration for `cancel_order` - # @return [::Gapic::Config::Method] - # - attr_reader :cancel_order - ## - # RPC-specific configuration for `list_sites` - # @return [::Gapic::Config::Method] - # - attr_reader :list_sites - ## - # RPC-specific configuration for `get_site` - # @return [::Gapic::Config::Method] - # - attr_reader :get_site - ## - # RPC-specific configuration for `create_site` - # @return [::Gapic::Config::Method] - # - attr_reader :create_site - ## - # RPC-specific configuration for `update_site` - # @return [::Gapic::Config::Method] - # - attr_reader :update_site - ## - # RPC-specific configuration for `delete_site` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_site - ## - # RPC-specific configuration for `list_hardware_groups` - # @return [::Gapic::Config::Method] - # - attr_reader :list_hardware_groups - ## - # RPC-specific configuration for `get_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :get_hardware_group - ## - # RPC-specific configuration for `create_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :create_hardware_group - ## - # RPC-specific configuration for `update_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :update_hardware_group - ## - # RPC-specific configuration for `delete_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_hardware_group - ## - # RPC-specific configuration for `list_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :list_hardware - ## - # RPC-specific configuration for `get_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :get_hardware - ## - # RPC-specific configuration for `create_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :create_hardware - ## - # RPC-specific configuration for `update_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :update_hardware - ## - # RPC-specific configuration for `delete_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_hardware - ## - # RPC-specific configuration for `list_comments` - # @return [::Gapic::Config::Method] - # - attr_reader :list_comments - ## - # RPC-specific configuration for `get_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :get_comment - ## - # RPC-specific configuration for `create_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :create_comment - ## - # RPC-specific configuration for `record_action_on_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :record_action_on_comment - ## - # RPC-specific configuration for `list_change_log_entries` - # @return [::Gapic::Config::Method] - # - attr_reader :list_change_log_entries - ## - # RPC-specific configuration for `get_change_log_entry` - # @return [::Gapic::Config::Method] - # - attr_reader :get_change_log_entry - ## - # RPC-specific configuration for `list_skus` - # @return [::Gapic::Config::Method] - # - attr_reader :list_skus - ## - # RPC-specific configuration for `get_sku` - # @return [::Gapic::Config::Method] - # - attr_reader :get_sku - ## - # RPC-specific configuration for `list_zones` - # @return [::Gapic::Config::Method] - # - attr_reader :list_zones - ## - # RPC-specific configuration for `get_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :get_zone - ## - # RPC-specific configuration for `create_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :create_zone - ## - # RPC-specific configuration for `update_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :update_zone - ## - # RPC-specific configuration for `delete_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_zone - ## - # RPC-specific configuration for `signal_zone_state` - # @return [::Gapic::Config::Method] - # - attr_reader :signal_zone_state - ## - # RPC-specific configuration for `request_order_date_change` - # @return [::Gapic::Config::Method] - # - attr_reader :request_order_date_change - - # @private - def initialize parent_rpcs = nil - list_orders_config = parent_rpcs.list_orders if parent_rpcs.respond_to? :list_orders - @list_orders = ::Gapic::Config::Method.new list_orders_config - get_order_config = parent_rpcs.get_order if parent_rpcs.respond_to? :get_order - @get_order = ::Gapic::Config::Method.new get_order_config - create_order_config = parent_rpcs.create_order if parent_rpcs.respond_to? :create_order - @create_order = ::Gapic::Config::Method.new create_order_config - update_order_config = parent_rpcs.update_order if parent_rpcs.respond_to? :update_order - @update_order = ::Gapic::Config::Method.new update_order_config - delete_order_config = parent_rpcs.delete_order if parent_rpcs.respond_to? :delete_order - @delete_order = ::Gapic::Config::Method.new delete_order_config - submit_order_config = parent_rpcs.submit_order if parent_rpcs.respond_to? :submit_order - @submit_order = ::Gapic::Config::Method.new submit_order_config - cancel_order_config = parent_rpcs.cancel_order if parent_rpcs.respond_to? :cancel_order - @cancel_order = ::Gapic::Config::Method.new cancel_order_config - list_sites_config = parent_rpcs.list_sites if parent_rpcs.respond_to? :list_sites - @list_sites = ::Gapic::Config::Method.new list_sites_config - get_site_config = parent_rpcs.get_site if parent_rpcs.respond_to? :get_site - @get_site = ::Gapic::Config::Method.new get_site_config - create_site_config = parent_rpcs.create_site if parent_rpcs.respond_to? :create_site - @create_site = ::Gapic::Config::Method.new create_site_config - update_site_config = parent_rpcs.update_site if parent_rpcs.respond_to? :update_site - @update_site = ::Gapic::Config::Method.new update_site_config - delete_site_config = parent_rpcs.delete_site if parent_rpcs.respond_to? :delete_site - @delete_site = ::Gapic::Config::Method.new delete_site_config - list_hardware_groups_config = parent_rpcs.list_hardware_groups if parent_rpcs.respond_to? :list_hardware_groups - @list_hardware_groups = ::Gapic::Config::Method.new list_hardware_groups_config - get_hardware_group_config = parent_rpcs.get_hardware_group if parent_rpcs.respond_to? :get_hardware_group - @get_hardware_group = ::Gapic::Config::Method.new get_hardware_group_config - create_hardware_group_config = parent_rpcs.create_hardware_group if parent_rpcs.respond_to? :create_hardware_group - @create_hardware_group = ::Gapic::Config::Method.new create_hardware_group_config - update_hardware_group_config = parent_rpcs.update_hardware_group if parent_rpcs.respond_to? :update_hardware_group - @update_hardware_group = ::Gapic::Config::Method.new update_hardware_group_config - delete_hardware_group_config = parent_rpcs.delete_hardware_group if parent_rpcs.respond_to? :delete_hardware_group - @delete_hardware_group = ::Gapic::Config::Method.new delete_hardware_group_config - list_hardware_config = parent_rpcs.list_hardware if parent_rpcs.respond_to? :list_hardware - @list_hardware = ::Gapic::Config::Method.new list_hardware_config - get_hardware_config = parent_rpcs.get_hardware if parent_rpcs.respond_to? :get_hardware - @get_hardware = ::Gapic::Config::Method.new get_hardware_config - create_hardware_config = parent_rpcs.create_hardware if parent_rpcs.respond_to? :create_hardware - @create_hardware = ::Gapic::Config::Method.new create_hardware_config - update_hardware_config = parent_rpcs.update_hardware if parent_rpcs.respond_to? :update_hardware - @update_hardware = ::Gapic::Config::Method.new update_hardware_config - delete_hardware_config = parent_rpcs.delete_hardware if parent_rpcs.respond_to? :delete_hardware - @delete_hardware = ::Gapic::Config::Method.new delete_hardware_config - list_comments_config = parent_rpcs.list_comments if parent_rpcs.respond_to? :list_comments - @list_comments = ::Gapic::Config::Method.new list_comments_config - get_comment_config = parent_rpcs.get_comment if parent_rpcs.respond_to? :get_comment - @get_comment = ::Gapic::Config::Method.new get_comment_config - create_comment_config = parent_rpcs.create_comment if parent_rpcs.respond_to? :create_comment - @create_comment = ::Gapic::Config::Method.new create_comment_config - record_action_on_comment_config = parent_rpcs.record_action_on_comment if parent_rpcs.respond_to? :record_action_on_comment - @record_action_on_comment = ::Gapic::Config::Method.new record_action_on_comment_config - list_change_log_entries_config = parent_rpcs.list_change_log_entries if parent_rpcs.respond_to? :list_change_log_entries - @list_change_log_entries = ::Gapic::Config::Method.new list_change_log_entries_config - get_change_log_entry_config = parent_rpcs.get_change_log_entry if parent_rpcs.respond_to? :get_change_log_entry - @get_change_log_entry = ::Gapic::Config::Method.new get_change_log_entry_config - list_skus_config = parent_rpcs.list_skus if parent_rpcs.respond_to? :list_skus - @list_skus = ::Gapic::Config::Method.new list_skus_config - get_sku_config = parent_rpcs.get_sku if parent_rpcs.respond_to? :get_sku - @get_sku = ::Gapic::Config::Method.new get_sku_config - list_zones_config = parent_rpcs.list_zones if parent_rpcs.respond_to? :list_zones - @list_zones = ::Gapic::Config::Method.new list_zones_config - get_zone_config = parent_rpcs.get_zone if parent_rpcs.respond_to? :get_zone - @get_zone = ::Gapic::Config::Method.new get_zone_config - create_zone_config = parent_rpcs.create_zone if parent_rpcs.respond_to? :create_zone - @create_zone = ::Gapic::Config::Method.new create_zone_config - update_zone_config = parent_rpcs.update_zone if parent_rpcs.respond_to? :update_zone - @update_zone = ::Gapic::Config::Method.new update_zone_config - delete_zone_config = parent_rpcs.delete_zone if parent_rpcs.respond_to? :delete_zone - @delete_zone = ::Gapic::Config::Method.new delete_zone_config - signal_zone_state_config = parent_rpcs.signal_zone_state if parent_rpcs.respond_to? :signal_zone_state - @signal_zone_state = ::Gapic::Config::Method.new signal_zone_state_config - request_order_date_change_config = parent_rpcs.request_order_date_change if parent_rpcs.respond_to? :request_order_date_change - @request_order_date_change = ::Gapic::Config::Method.new request_order_date_change_config - - yield self if block_given? - end - end - end - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb deleted file mode 100644 index f71ab8bc016f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "googleauth" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - # Credentials for the GDCHardwareManagement API. - class Credentials < ::Google::Auth::Credentials - self.scope = [ - "https://www.googleapis.com/auth/cloud-platform" - ] - self.env_vars = [ - "GOOGLE_CLOUD_CREDENTIALS", - "GOOGLE_CLOUD_KEYFILE", - "GCLOUD_KEYFILE", - "GOOGLE_CLOUD_CREDENTIALS_JSON", - "GOOGLE_CLOUD_KEYFILE_JSON", - "GCLOUD_KEYFILE_JSON" - ] - self.paths = [ - "~/.config/google_cloud/application_default_credentials.json" - ] - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb deleted file mode 100644 index 284b8f8b9f8c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/operations.rb +++ /dev/null @@ -1,841 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "gapic/operation" -require "google/longrunning/operations_pb" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - # Service that implements Longrunning Operations API. - class Operations - # @private - API_VERSION = "" - - # @private - DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" - - # @private - attr_reader :operations_stub - - ## - # Configuration for the GDCHardwareManagement Operations API. - # - # @yield [config] Configure the Operations client. - # @yieldparam config [Operations::Configuration] - # - # @return [Operations::Configuration] - # - def self.configure - @configure ||= Operations::Configuration.new - yield @configure if block_given? - @configure - end - - ## - # Configure the GDCHardwareManagement Operations instance. - # - # The configuration is set to the derived mode, meaning that values can be changed, - # but structural changes (adding new fields, etc.) are not allowed. Structural changes - # should be made on {Operations.configure}. - # - # @yield [config] Configure the Operations client. - # @yieldparam config [Operations::Configuration] - # - # @return [Operations::Configuration] - # - def configure - yield @config if block_given? - @config - end - - ## - # The effective universe domain - # - # @return [String] - # - def universe_domain - @operations_stub.universe_domain - end - - ## - # Create a new Operations client object. - # - # @yield [config] Configure the Client client. - # @yieldparam config [Operations::Configuration] - # - def initialize - # These require statements are intentionally placed here to initialize - # the gRPC module only when it's required. - # See https://github.com/googleapis/toolkit/issues/446 - require "gapic/grpc" - require "google/longrunning/operations_services_pb" - - # Create the configuration object - @config = Configuration.new Operations.configure - - # Yield the configuration if needed - yield @config if block_given? - - # Create credentials - credentials = @config.credentials - credentials ||= Credentials.default scope: @config.scope - if credentials.is_a?(::String) || credentials.is_a?(::Hash) - credentials = Credentials.new credentials, scope: @config.scope - end - @quota_project_id = @config.quota_project - @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id - - @operations_stub = ::Gapic::ServiceStub.new( - ::Google::Longrunning::Operations::Stub, - credentials: credentials, - endpoint: @config.endpoint, - endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, - universe_domain: @config.universe_domain, - channel_args: @config.channel_args, - interceptors: @config.interceptors, - channel_pool_config: @config.channel_pool - ) - - # Used by an LRO wrapper for some methods of this service - @operations_client = self - end - - # Service calls - - ## - # Lists operations that match the specified filter in the request. If the - # server doesn't support this method, it returns `UNIMPLEMENTED`. - # - # @overload list_operations(request, options = nil) - # Pass arguments to `list_operations` via a request object, either of type - # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::ListOperationsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload list_operations(name: nil, filter: nil, page_size: nil, page_token: nil, return_partial_success: nil) - # Pass arguments to `list_operations` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation's parent resource. - # @param filter [::String] - # The standard list filter. - # @param page_size [::Integer] - # The standard list page size. - # @param page_token [::String] - # The standard list page token. - # @param return_partial_success [::Boolean] - # When set to `true`, operations that are reachable are returned as normal, - # and those that are unreachable are returned in the - # [ListOperationsResponse.unreachable] field. - # - # This can only be `true` when reading across collections e.g. when `parent` - # is set to `"projects/example/locations/-"`. - # - # This field is not by default supported and will result in an - # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in - # service or product specific documentation. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::PagedEnumerable<::Gapic::Operation>] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::PagedEnumerable<::Gapic::Operation>] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::ListOperationsRequest.new - # - # # Call the list_operations method. - # result = client.list_operations request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Longrunning::Operation. - # p item - # end - # - def list_operations request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::ListOperationsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.list_operations.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.list_operations.timeout, - metadata: metadata, - retry_policy: @config.rpcs.list_operations.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.call_rpc :list_operations, request, options: options do |response, operation| - wrap_lro_operation = ->(op_response) { ::Gapic::Operation.new op_response, @operations_client } - response = ::Gapic::PagedEnumerable.new @operations_stub, :list_operations, request, response, operation, options, format_resource: wrap_lro_operation - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets the latest state of a long-running operation. Clients can use this - # method to poll the operation result at intervals as recommended by the API - # service. - # - # @overload get_operation(request, options = nil) - # Pass arguments to `get_operation` via a request object, either of type - # {::Google::Longrunning::GetOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::GetOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload get_operation(name: nil) - # Pass arguments to `get_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::GetOperationRequest.new - # - # # Call the get_operation method. - # result = client.get_operation request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def get_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::GetOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.get_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.get_operation.timeout, - metadata: metadata, - retry_policy: @config.rpcs.get_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.call_rpc :get_operation, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a long-running operation. This method indicates that the client is - # no longer interested in the operation result. It does not cancel the - # operation. If the server doesn't support this method, it returns - # `google.rpc.Code.UNIMPLEMENTED`. - # - # @overload delete_operation(request, options = nil) - # Pass arguments to `delete_operation` via a request object, either of type - # {::Google::Longrunning::DeleteOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::DeleteOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload delete_operation(name: nil) - # Pass arguments to `delete_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource to be deleted. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Protobuf::Empty] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Protobuf::Empty] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::DeleteOperationRequest.new - # - # # Call the delete_operation method. - # result = client.delete_operation request - # - # # The returned object is of type Google::Protobuf::Empty. - # p result - # - def delete_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::DeleteOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.delete_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.delete_operation.timeout, - metadata: metadata, - retry_policy: @config.rpcs.delete_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Starts asynchronous cancellation on a long-running operation. The server - # makes a best effort to cancel the operation, but success is not - # guaranteed. If the server doesn't support this method, it returns - # `google.rpc.Code.UNIMPLEMENTED`. Clients can use - # Operations.GetOperation or - # other methods to check whether the cancellation succeeded or whether the - # operation completed despite cancellation. On successful cancellation, - # the operation is not deleted; instead, it becomes an operation with - # an {::Google::Longrunning::Operation#error Operation.error} value with a - # {::Google::Rpc::Status#code google.rpc.Status.code} of `1`, corresponding to - # `Code.CANCELLED`. - # - # @overload cancel_operation(request, options = nil) - # Pass arguments to `cancel_operation` via a request object, either of type - # {::Google::Longrunning::CancelOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::CancelOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload cancel_operation(name: nil) - # Pass arguments to `cancel_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource to be cancelled. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Google::Protobuf::Empty] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Google::Protobuf::Empty] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::CancelOperationRequest.new - # - # # Call the cancel_operation method. - # result = client.cancel_operation request - # - # # The returned object is of type Google::Protobuf::Empty. - # p result - # - def cancel_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::CancelOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.cancel_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - header_params = {} - if request.name - header_params["name"] = request.name - end - - request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&") - metadata[:"x-goog-request-params"] ||= request_params_header - - options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout, - metadata: metadata, - retry_policy: @config.rpcs.cancel_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation| - yield response, operation if block_given? - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Waits until the specified long-running operation is done or reaches at most - # a specified timeout, returning the latest state. If the operation is - # already done, the latest state is immediately returned. If the timeout - # specified is greater than the default HTTP/RPC timeout, the HTTP/RPC - # timeout is used. If the server does not support this method, it returns - # `google.rpc.Code.UNIMPLEMENTED`. - # Note that this method is on a best-effort basis. It may return the latest - # state before the specified timeout (including immediately), meaning even an - # immediate response is no guarantee that the operation is done. - # - # @overload wait_operation(request, options = nil) - # Pass arguments to `wait_operation` via a request object, either of type - # {::Google::Longrunning::WaitOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::WaitOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional. - # - # @overload wait_operation(name: nil, timeout: nil) - # Pass arguments to `wait_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource to wait on. - # @param timeout [::Google::Protobuf::Duration, ::Hash] - # The maximum duration to wait before timing out. If left blank, the wait - # will be at most the time permitted by the underlying HTTP/RPC protocol. - # If RPC context deadline is also specified, the shorter one will be used. - # - # @yield [response, operation] Access the result along with the RPC operation - # @yieldparam response [::Gapic::Operation] - # @yieldparam operation [::GRPC::ActiveCall::Operation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the RPC is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::WaitOperationRequest.new - # - # # Call the wait_operation method. - # result = client.wait_operation request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def wait_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::WaitOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - metadata = @config.rpcs.wait_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION - metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.wait_operation.timeout, - metadata: metadata, - retry_policy: @config.rpcs.wait_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation| - response = ::Gapic::Operation.new response, @operations_client, options: options - yield response, operation if block_given? - throw :response, response - end - rescue ::GRPC::BadStatus => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Configuration class for the Operations API. - # - # This class represents the configuration for Operations, - # providing control over timeouts, retry behavior, logging, transport - # parameters, and other low-level controls. Certain parameters can also be - # applied individually to specific RPCs. See - # {::Google::Longrunning::Operations::Client::Configuration::Rpcs} - # for a list of RPCs that can be configured independently. - # - # Configuration can be applied globally to all clients, or to a single client - # on construction. - # - # @example - # - # # Modify the global config, setting the timeout for - # # list_operations to 20 seconds, - # # and all remaining timeouts to 10 seconds. - # ::Google::Longrunning::Operations::Client.configure do |config| - # config.timeout = 10.0 - # config.rpcs.list_operations.timeout = 20.0 - # end - # - # # Apply the above configuration only to a new client. - # client = ::Google::Longrunning::Operations::Client.new do |config| - # config.timeout = 10.0 - # config.rpcs.list_operations.timeout = 20.0 - # end - # - # @!attribute [rw] endpoint - # A custom service endpoint, as a hostname or hostname:port. The default is - # nil, indicating to use the default endpoint in the current universe domain. - # @return [::String,nil] - # @!attribute [rw] credentials - # Credentials to send with calls. You may provide any of the following types: - # * (`Google::Auth::Credentials`) A googleauth credentials object - # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) - # * (`Signet::OAuth2::Client`) A signet oauth2 client object - # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) - # * (`GRPC::Core::Channel`) a gRPC channel with included credentials - # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object - # * (`nil`) indicating no credentials - # - # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials - # is deprecated. Providing an unvalidated credential configuration to - # Google APIs can compromise the security of your systems and data. - # - # @example - # - # # The recommended way to provide credentials is to use the `make_creds` method - # # on the appropriate credentials class for your environment. - # - # require "googleauth" - # - # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds( - # json_key_io: ::File.open("/path/to/keyfile.json") - # ) - # - # client = ::Google::Longrunning::Operations::Client.new do |config| - # config.credentials = credentials - # end - # - # @note Warning: If you accept a credential configuration (JSON file or Hash) from an - # external source for authentication to Google Cloud, you must validate it before - # providing it to a Google API client library. Providing an unvalidated credential - # configuration to Google APIs can compromise the security of your systems and data. - # For more information, refer to [Validate credential configurations from external - # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). - # @return [::Object] - # @!attribute [rw] scope - # The OAuth scopes - # @return [::Array<::String>] - # @!attribute [rw] lib_name - # The library name as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] lib_version - # The library version as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] channel_args - # Extra parameters passed to the gRPC channel. Note: this is ignored if a - # `GRPC::Core::Channel` object is provided as the credential. - # @return [::Hash] - # @!attribute [rw] interceptors - # An array of interceptors that are run before calls are executed. - # @return [::Array<::GRPC::ClientInterceptor>] - # @!attribute [rw] timeout - # The call timeout in seconds. - # @return [::Numeric] - # @!attribute [rw] metadata - # Additional gRPC headers to be sent with the call. - # @return [::Hash{::Symbol=>::String}] - # @!attribute [rw] retry_policy - # The retry policy. The value is a hash with the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # @return [::Hash] - # @!attribute [rw] quota_project - # A separate project against which to charge quota. - # @return [::String] - # @!attribute [rw] universe_domain - # The universe domain within which to make requests. This determines the - # default endpoint URL. The default value of nil uses the environment - # universe (usually the default "googleapis.com" universe). - # @return [::String,nil] - # @!attribute [rw] logger - # A custom logger to use for request/response debug logging, or the value - # `:default` (the default) to construct a default logger, or `nil` to - # explicitly disable logging. - # @return [::Logger,:default,nil] - # - class Configuration - extend ::Gapic::Config - - # @private - # The endpoint specific to the default "googleapis.com" universe. Deprecated. - DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" - - config_attr :endpoint, nil, ::String, nil - config_attr :credentials, nil do |value| - allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] - allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC::Core::Channel - allowed.any? { |klass| klass === value } - end - config_attr :scope, nil, ::String, ::Array, nil - config_attr :lib_name, nil, ::String, nil - config_attr :lib_version, nil, ::String, nil - config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil) - config_attr :interceptors, nil, ::Array, nil - config_attr :timeout, nil, ::Numeric, nil - config_attr :metadata, nil, ::Hash, nil - config_attr :retry_policy, nil, ::Hash, ::Proc, nil - config_attr :quota_project, nil, ::String, nil - config_attr :universe_domain, nil, ::String, nil - config_attr :logger, :default, ::Logger, nil, :default - - # @private - def initialize parent_config = nil - @parent_config = parent_config unless parent_config.nil? - - yield self if block_given? - end - - ## - # Configurations for individual RPCs - # @return [Rpcs] - # - def rpcs - @rpcs ||= begin - parent_rpcs = nil - parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) - Rpcs.new parent_rpcs - end - end - - ## - # Configuration for the channel pool - # @return [::Gapic::ServiceStub::ChannelPool::Configuration] - # - def channel_pool - @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new - end - - ## - # Configuration RPC class for the Operations API. - # - # Includes fields providing the configuration for each RPC in this service. - # Each configuration object is of type `Gapic::Config::Method` and includes - # the following configuration fields: - # - # * `timeout` (*type:* `Numeric`) - The call timeout in seconds - # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers - # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields - # include the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # - class Rpcs - ## - # RPC-specific configuration for `list_operations` - # @return [::Gapic::Config::Method] - # - attr_reader :list_operations - ## - # RPC-specific configuration for `get_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :get_operation - ## - # RPC-specific configuration for `delete_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_operation - ## - # RPC-specific configuration for `cancel_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :cancel_operation - ## - # RPC-specific configuration for `wait_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :wait_operation - - # @private - def initialize parent_rpcs = nil - list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations - @list_operations = ::Gapic::Config::Method.new list_operations_config - get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation - @get_operation = ::Gapic::Config::Method.new get_operation_config - delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation - @delete_operation = ::Gapic::Config::Method.new delete_operation_config - cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation - @cancel_operation = ::Gapic::Config::Method.new cancel_operation_config - wait_operation_config = parent_rpcs.wait_operation if parent_rpcs.respond_to? :wait_operation - @wait_operation = ::Gapic::Config::Method.new wait_operation_config - - yield self if block_given? - end - end - end - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb deleted file mode 100644 index 37a35977c460..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths.rb +++ /dev/null @@ -1,208 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - # Path helper methods for the GDCHardwareManagement API. - module Paths - ## - # Create a fully-qualified ChangeLogEntry resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` - # - # @param project [String] - # @param location [String] - # @param order [String] - # @param change_log_entry [String] - # - # @return [::String] - def change_log_entry_path project:, location:, order:, change_log_entry: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" - - "projects/#{project}/locations/#{location}/orders/#{order}/changeLogEntries/#{change_log_entry}" - end - - ## - # Create a fully-qualified Comment resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # - # @param project [String] - # @param location [String] - # @param order [String] - # @param comment [String] - # - # @return [::String] - def comment_path project:, location:, order:, comment: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" - - "projects/#{project}/locations/#{location}/orders/#{order}/comments/#{comment}" - end - - ## - # Create a fully-qualified Hardware resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/hardware/{hardware}` - # - # @param project [String] - # @param location [String] - # @param hardware [String] - # - # @return [::String] - def hardware_path project:, location:, hardware: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - - "projects/#{project}/locations/#{location}/hardware/#{hardware}" - end - - ## - # Create a fully-qualified HardwareGroup resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # - # @param project [String] - # @param location [String] - # @param order [String] - # @param hardware_group [String] - # - # @return [::String] - def hardware_group_path project:, location:, order:, hardware_group: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - raise ::ArgumentError, "order cannot contain /" if order.to_s.include? "/" - - "projects/#{project}/locations/#{location}/orders/#{order}/hardwareGroups/#{hardware_group}" - end - - ## - # Create a fully-qualified Location resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}` - # - # @param project [String] - # @param location [String] - # - # @return [::String] - def location_path project:, location: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - - "projects/#{project}/locations/#{location}" - end - - ## - # Create a fully-qualified Order resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/orders/{order}` - # - # @param project [String] - # @param location [String] - # @param order [String] - # - # @return [::String] - def order_path project:, location:, order: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - - "projects/#{project}/locations/#{location}/orders/#{order}" - end - - ## - # Create a fully-qualified Site resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/sites/{site}` - # - # @param project [String] - # @param location [String] - # @param site [String] - # - # @return [::String] - def site_path project:, location:, site: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - - "projects/#{project}/locations/#{location}/sites/#{site}" - end - - ## - # Create a fully-qualified Sku resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/skus/{sku}` - # - # @param project [String] - # @param location [String] - # @param sku [String] - # - # @return [::String] - def sku_path project:, location:, sku: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - - "projects/#{project}/locations/#{location}/skus/#{sku}" - end - - ## - # Create a fully-qualified Zone resource string. - # - # The resource will be in the following format: - # - # `projects/{project}/locations/{location}/zones/{zone}` - # - # @param project [String] - # @param location [String] - # @param zone [String] - # - # @return [::String] - def zone_path project:, location:, zone: - raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" - raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" - - "projects/#{project}/locations/#{location}/zones/#{zone}" - end - - extend self - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb deleted file mode 100644 index a6427b850375..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "gapic/rest" -require "gapic/config" -require "gapic/config/method" - -require "google/cloud/gdc_hardware_management/v1alpha/version" -require "google/cloud/gdc_hardware_management/v1alpha/bindings_override" - -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/credentials" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/paths" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - ## - # The GDC Hardware Management service. - # - # To load this service and instantiate a REST client: - # - # require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - module GDCHardwareManagement - # Client for the REST transport - module Rest - end - end - end - end - end -end - -helper_path = ::File.join __dir__, "rest", "helpers.rb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/helpers" if ::File.file? helper_path diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb deleted file mode 100644 index a682f54057ca..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/client.rb +++ /dev/null @@ -1,4205 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "google/cloud/errors" -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub" -require "google/cloud/location/rest" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - module Rest - ## - # REST client for the GDCHardwareManagement service. - # - # The GDC Hardware Management service. - # - class Client - # @private - API_VERSION = "" - - # @private - DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" - - include Paths - - # @private - attr_reader :gdc_hardware_management_stub - - ## - # Configure the GDCHardwareManagement Client class. - # - # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration} - # for a description of the configuration fields. - # - # @example - # - # # Modify the configuration for all GDCHardwareManagement clients - # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.configure do |config| - # config.timeout = 10.0 - # end - # - # @yield [config] Configure the Client client. - # @yieldparam config [Client::Configuration] - # - # @return [Client::Configuration] - # - def self.configure - @configure ||= begin - namespace = ["Google", "Cloud", "GDCHardwareManagement", "V1alpha"] - parent_config = while namespace.any? - parent_name = namespace.join "::" - parent_const = const_get parent_name - break parent_const.configure if parent_const.respond_to? :configure - namespace.pop - end - default_config = Client::Configuration.new parent_config - - default_config.rpcs.list_orders.timeout = 60.0 - default_config.rpcs.list_orders.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_order.timeout = 60.0 - default_config.rpcs.get_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_order.timeout = 60.0 - - default_config.rpcs.update_order.timeout = 60.0 - default_config.rpcs.update_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_order.timeout = 60.0 - default_config.rpcs.delete_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.submit_order.timeout = 60.0 - default_config.rpcs.submit_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.cancel_order.timeout = 60.0 - default_config.rpcs.cancel_order.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_sites.timeout = 60.0 - default_config.rpcs.list_sites.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_site.timeout = 60.0 - default_config.rpcs.get_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_site.timeout = 60.0 - - default_config.rpcs.update_site.timeout = 60.0 - default_config.rpcs.update_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_site.timeout = 60.0 - default_config.rpcs.delete_site.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_hardware_groups.timeout = 60.0 - default_config.rpcs.list_hardware_groups.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_hardware_group.timeout = 60.0 - default_config.rpcs.get_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_hardware_group.timeout = 60.0 - - default_config.rpcs.update_hardware_group.timeout = 60.0 - default_config.rpcs.update_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_hardware_group.timeout = 60.0 - default_config.rpcs.delete_hardware_group.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_hardware.timeout = 60.0 - default_config.rpcs.list_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_hardware.timeout = 60.0 - default_config.rpcs.get_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_hardware.timeout = 60.0 - - default_config.rpcs.update_hardware.timeout = 60.0 - default_config.rpcs.update_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_hardware.timeout = 60.0 - default_config.rpcs.delete_hardware.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_comments.timeout = 60.0 - default_config.rpcs.list_comments.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_comment.timeout = 60.0 - default_config.rpcs.get_comment.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_comment.timeout = 60.0 - - default_config.rpcs.list_change_log_entries.timeout = 60.0 - default_config.rpcs.list_change_log_entries.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_change_log_entry.timeout = 60.0 - default_config.rpcs.get_change_log_entry.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_skus.timeout = 60.0 - default_config.rpcs.list_skus.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_sku.timeout = 60.0 - default_config.rpcs.get_sku.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.list_zones.timeout = 60.0 - default_config.rpcs.list_zones.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.get_zone.timeout = 60.0 - default_config.rpcs.get_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.create_zone.timeout = 60.0 - - default_config.rpcs.update_zone.timeout = 60.0 - default_config.rpcs.update_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config.rpcs.delete_zone.timeout = 60.0 - default_config.rpcs.delete_zone.retry_policy = { - initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] - } - - default_config - end - yield @configure if block_given? - @configure - end - - ## - # Configure the GDCHardwareManagement Client instance. - # - # The configuration is set to the derived mode, meaning that values can be changed, - # but structural changes (adding new fields, etc.) are not allowed. Structural changes - # should be made on {Client.configure}. - # - # See {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration} - # for a description of the configuration fields. - # - # @yield [config] Configure the Client client. - # @yieldparam config [Client::Configuration] - # - # @return [Client::Configuration] - # - def configure - yield @config if block_given? - @config - end - - ## - # The effective universe domain - # - # @return [String] - # - def universe_domain - @gdc_hardware_management_stub.universe_domain - end - - ## - # Create a new GDCHardwareManagement REST client object. - # - # @example - # - # # Create a client using the default configuration - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a client using a custom configuration - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - # config.timeout = 10.0 - # end - # - # @yield [config] Configure the GDCHardwareManagement client. - # @yieldparam config [Client::Configuration] - # - def initialize - # Create the configuration object - @config = Configuration.new Client.configure - - # Yield the configuration if needed - yield @config if block_given? - - # Create credentials - credentials = @config.credentials - # Use self-signed JWT if the endpoint is unchanged from default, - # but only if the default endpoint does not have a region prefix. - enable_self_signed_jwt = @config.endpoint.nil? || - (@config.endpoint == Configuration::DEFAULT_ENDPOINT && - !@config.endpoint.split(".").first.include?("-")) - credentials ||= Credentials.default scope: @config.scope, - enable_self_signed_jwt: enable_self_signed_jwt - if credentials.is_a?(::String) || credentials.is_a?(::Hash) - credentials = Credentials.new credentials, scope: @config.scope - end - - @quota_project_id = @config.quota_project - @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id - - @operations_client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Operations.new do |config| - config.credentials = credentials - config.quota_project = @quota_project_id - config.endpoint = @config.endpoint - config.universe_domain = @config.universe_domain - end - - @gdc_hardware_management_stub = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.new( - endpoint: @config.endpoint, - endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, - universe_domain: @config.universe_domain, - credentials: credentials, - logger: @config.logger - ) - - @gdc_hardware_management_stub.logger(stub: true)&.info do |entry| - entry.set_system_name - entry.set_service - entry.message = "Created client for #{entry.service}" - entry.set_credentials_fields credentials - entry.set "customEndpoint", @config.endpoint if @config.endpoint - entry.set "defaultTimeout", @config.timeout if @config.timeout - entry.set "quotaProject", @quota_project_id if @quota_project_id - end - - @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config| - config.credentials = credentials - config.quota_project = @quota_project_id - config.endpoint = @gdc_hardware_management_stub.endpoint - config.universe_domain = @gdc_hardware_management_stub.universe_domain - config.bindings_override = @config.bindings_override - config.logger = @gdc_hardware_management_stub.logger if config.respond_to? :logger= - end - end - - ## - # Get the associated client for long-running operations. - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Operations] - # - attr_reader :operations_client - - ## - # Get the associated client for mix-in of the Locations. - # - # @return [Google::Cloud::Location::Locations::Rest::Client] - # - attr_reader :location_client - - ## - # The logger used for request/response debug logging. - # - # @return [Logger] - # - def logger - @gdc_hardware_management_stub.logger - end - - # Service calls - - ## - # Lists orders in a given project and location. - # - # @overload list_orders(request, options = nil) - # Pass arguments to `list_orders` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_orders(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_orders` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list orders in. - # Format: `projects/{project}/locations/{location}` - # - # To list orders across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new - # - # # Call the list_orders method. - # result = client.list_orders request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. - # p item - # end - # - def list_orders request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_orders.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_orders.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_orders.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_orders request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_orders, "orders", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of an order. - # - # @overload get_order(request, options = nil) - # Pass arguments to `get_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_order(name: nil) - # Pass arguments to `get_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. Name of the resource - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new - # - # # Call the get_order method. - # result = client.get_order request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. - # p result - # - def get_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_order request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new order in a given project and location. - # - # @overload create_order(request, options = nil) - # Pass arguments to `create_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_order(parent: nil, order_id: nil, order: nil, request_id: nil) - # Pass arguments to `create_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the order in. - # Format: `projects/{project}/locations/{location}` - # @param order_id [::String] - # Optional. ID used to uniquely identify the Order within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The order.name field in the request will be ignored. - # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] - # Required. The order to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new - # - # # Call the create_order method. - # result = client.create_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_order request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of an order. - # - # @overload update_order(request, options = nil) - # Pass arguments to `update_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload update_order(update_mask: nil, order: nil, request_id: nil) - # Pass arguments to `update_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Order to overwrite with this - # update. The fields specified in the update_mask are relative to the order, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param order [::Google::Cloud::GDCHardwareManagement::V1alpha::Order, ::Hash] - # Required. The order to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new - # - # # Call the update_order method. - # result = client.update_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.update_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.update_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.update_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.update_order request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes an order. - # - # @overload delete_order(request, options = nil) - # Pass arguments to `delete_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_order(name: nil, request_id: nil, force: nil) - # Pass arguments to `delete_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param force [::Boolean] - # Optional. An option to delete any nested resources in the Order, such as a - # HardwareGroup. If true, any nested resources for this Order will also be - # deleted. Otherwise, the request will only succeed if the Order has no - # nested resources. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new - # - # # Call the delete_order method. - # result = client.delete_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.delete_order request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Submits an order. - # - # @overload submit_order(request, options = nil) - # Pass arguments to `submit_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload submit_order(name: nil, request_id: nil, type: nil) - # Pass arguments to `submit_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param type [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] - # Optional. Type of this request. If unset, the request type is assumed to be - # `INFO_PENDING`. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new - # - # # Call the submit_order method. - # result = client.submit_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def submit_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.submit_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.submit_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.submit_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.submit_order request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Cancels an order. - # - # @overload cancel_order(request, options = nil) - # Pass arguments to `cancel_order` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload cancel_order(name: nil, request_id: nil) - # Pass arguments to `cancel_order` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new - # - # # Call the cancel_order method. - # result = client.cancel_order request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def cancel_order request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.cancel_order.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.cancel_order.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.cancel_order.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.cancel_order request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists sites in a given project and location. - # - # @overload list_sites(request, options = nil) - # Pass arguments to `list_sites` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_sites(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_sites` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list sites in. - # Format: `projects/{project}/locations/{location}` - # - # To list sites across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new - # - # # Call the list_sites method. - # result = client.list_sites request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. - # p item - # end - # - def list_sites request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_sites.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_sites.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_sites.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_sites request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_sites, "sites", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a site. - # - # @overload get_site(request, options = nil) - # Pass arguments to `get_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_site(name: nil) - # Pass arguments to `get_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new - # - # # Call the get_site method. - # result = client.get_site request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. - # p result - # - def get_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_site.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_site request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new site in a given project and location. - # - # @overload create_site(request, options = nil) - # Pass arguments to `create_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_site(parent: nil, site_id: nil, site: nil, request_id: nil) - # Pass arguments to `create_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the site in. - # Format: `projects/{project}/locations/{location}` - # @param site_id [::String] - # Optional. ID used to uniquely identify the Site within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The site.name field in the request will be ignored. - # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] - # Required. The site to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new - # - # # Call the create_site method. - # result = client.create_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_site.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_site request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a site. - # - # @overload update_site(request, options = nil) - # Pass arguments to `update_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload update_site(update_mask: nil, site: nil, request_id: nil) - # Pass arguments to `update_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Site to overwrite with this - # update. The fields specified in the update_mask are relative to the site, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param site [::Google::Cloud::GDCHardwareManagement::V1alpha::Site, ::Hash] - # Required. The site to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new - # - # # Call the update_site method. - # result = client.update_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.update_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.update_site.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.update_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.update_site request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a site. - # - # @overload delete_site(request, options = nil) - # Pass arguments to `delete_site` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_site(name: nil, request_id: nil) - # Pass arguments to `delete_site` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new - # - # # Call the delete_site method. - # result = client.delete_site request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_site request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_site.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_site.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_site.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.delete_site request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists hardware groups in a given order. - # - # @overload list_hardware_groups(request, options = nil) - # Pass arguments to `list_hardware_groups` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_hardware_groups(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_hardware_groups` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list hardware groups in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new - # - # # Call the list_hardware_groups method. - # result = client.list_hardware_groups request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - # p item - # end - # - def list_hardware_groups request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_hardware_groups.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_hardware_groups.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_hardware_groups.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_hardware_groups request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware_groups, "hardware_groups", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a hardware group. - # - # @overload get_hardware_group(request, options = nil) - # Pass arguments to `get_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_hardware_group(name: nil) - # Pass arguments to `get_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new - # - # # Call the get_hardware_group method. - # result = client.get_hardware_group request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - # p result - # - def get_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_hardware_group.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_hardware_group request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new hardware group in a given order. - # - # @overload create_hardware_group(request, options = nil) - # Pass arguments to `create_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_hardware_group(parent: nil, hardware_group_id: nil, hardware_group: nil, request_id: nil) - # Pass arguments to `create_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to create the hardware group in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param hardware_group_id [::String] - # Optional. ID used to uniquely identify the HardwareGroup within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware_group.name field in the request will be ignored. - # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] - # Required. The hardware group to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new - # - # # Call the create_hardware_group method. - # result = client.create_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_hardware_group.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_hardware_group request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a hardware group. - # - # @overload update_hardware_group(request, options = nil) - # Pass arguments to `update_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload update_hardware_group(update_mask: nil, hardware_group: nil, request_id: nil) - # Pass arguments to `update_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the HardwareGroup to overwrite - # with this update. The fields specified in the update_mask are relative to - # the hardware group, not the full request. A field will be overwritten if it - # is in the mask. If you don't provide a mask then all fields will be - # overwritten. - # @param hardware_group [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup, ::Hash] - # Required. The hardware group to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new - # - # # Call the update_hardware_group method. - # result = client.update_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.update_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.update_hardware_group.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.update_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.update_hardware_group request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a hardware group. - # - # @overload delete_hardware_group(request, options = nil) - # Pass arguments to `delete_hardware_group` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_hardware_group(name: nil, request_id: nil) - # Pass arguments to `delete_hardware_group` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new - # - # # Call the delete_hardware_group method. - # result = client.delete_hardware_group request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_hardware_group request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_hardware_group.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_hardware_group.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_hardware_group.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.delete_hardware_group request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists hardware in a given project and location. - # - # @overload list_hardware(request, options = nil) - # Pass arguments to `list_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_hardware(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list hardware in. - # Format: `projects/{project}/locations/{location}` - # - # To list hardware across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new - # - # # Call the list_hardware method. - # result = client.list_hardware request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - # p item - # end - # - def list_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_hardware.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_hardware request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_hardware, "hardware", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets hardware details. - # - # @overload get_hardware(request, options = nil) - # Pass arguments to `get_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_hardware(name: nil) - # Pass arguments to `get_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new - # - # # Call the get_hardware method. - # result = client.get_hardware request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - # p result - # - def get_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_hardware.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_hardware request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates new hardware in a given project and location. - # - # @overload create_hardware(request, options = nil) - # Pass arguments to `create_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_hardware(parent: nil, hardware_id: nil, hardware: nil) - # Pass arguments to `create_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create hardware in. - # Format: `projects/{project}/locations/{location}` - # @param hardware_id [::String] - # Optional. ID used to uniquely identify the Hardware within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware.name field in the request will be ignored. - # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] - # Required. The resource to create. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new - # - # # Call the create_hardware method. - # result = client.create_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_hardware.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_hardware request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates hardware parameters. - # - # @overload update_hardware(request, options = nil) - # Pass arguments to `update_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload update_hardware(update_mask: nil, hardware: nil, request_id: nil) - # Pass arguments to `update_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Hardware to overwrite with - # this update. The fields specified in the update_mask are relative to the - # hardware, not the full request. A field will be overwritten if it is in the - # mask. If you don't provide a mask then all fields will be overwritten. - # @param hardware [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware, ::Hash] - # Required. The hardware to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new - # - # # Call the update_hardware method. - # result = client.update_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.update_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.update_hardware.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.update_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.update_hardware request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes hardware. - # - # @overload delete_hardware(request, options = nil) - # Pass arguments to `delete_hardware` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_hardware(name: nil, request_id: nil) - # Pass arguments to `delete_hardware` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new - # - # # Call the delete_hardware method. - # result = client.delete_hardware request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_hardware request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_hardware.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_hardware.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_hardware.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.delete_hardware request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists the comments on an order. - # - # @overload list_comments(request, options = nil) - # Pass arguments to `list_comments` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_comments(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_comments` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list comments on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new - # - # # Call the list_comments method. - # result = client.list_comments request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p item - # end - # - def list_comments request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_comments.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_comments.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_comments.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_comments request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_comments, "comments", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets the content of a comment. - # - # @overload get_comment(request, options = nil) - # Pass arguments to `get_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_comment(name: nil) - # Pass arguments to `get_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new - # - # # Call the get_comment method. - # result = client.get_comment request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p result - # - def get_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_comment.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_comment request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new comment on an order. - # - # @overload create_comment(request, options = nil) - # Pass arguments to `create_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_comment(parent: nil, comment_id: nil, comment: nil, request_id: nil) - # Pass arguments to `create_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to create the comment on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param comment_id [::String] - # Optional. ID used to uniquely identify the Comment within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The comment.name field in the request will be ignored. - # @param comment [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment, ::Hash] - # Required. The comment to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new - # - # # Call the create_comment method. - # result = client.create_comment request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_comment.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_comment request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Record Action on a Comment. If the Action specified in the request is READ, - # the viewed time in the comment is set to the time the request was received. - # If the comment is already marked as read, subsequent calls will be ignored. - # If the Action is UNREAD, the viewed time is cleared from the comment. - # - # @overload record_action_on_comment(request, options = nil) - # Pass arguments to `record_action_on_comment` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload record_action_on_comment(name: nil, action_type: nil) - # Pass arguments to `record_action_on_comment` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # @param action_type [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] - # Required. The action type of the recorded action. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new - # - # # Call the record_action_on_comment method. - # result = client.record_action_on_comment request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - # p result - # - def record_action_on_comment request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.record_action_on_comment.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.record_action_on_comment.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.record_action_on_comment.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.record_action_on_comment request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists the changes made to an order. - # - # @overload list_change_log_entries(request, options = nil) - # Pass arguments to `list_change_log_entries` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_change_log_entries(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_change_log_entries` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The order to list change log entries for. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new - # - # # Call the list_change_log_entries method. - # result = client.list_change_log_entries request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - # p item - # end - # - def list_change_log_entries request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_change_log_entries.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_change_log_entries.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_change_log_entries.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_change_log_entries request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_change_log_entries, "change_log_entries", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a change to an order. - # - # @overload get_change_log_entry(request, options = nil) - # Pass arguments to `get_change_log_entry` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_change_log_entry(name: nil) - # Pass arguments to `get_change_log_entry` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the change log entry. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new - # - # # Call the get_change_log_entry method. - # result = client.get_change_log_entry request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - # p result - # - def get_change_log_entry request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_change_log_entry.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_change_log_entry.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_change_log_entry.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_change_log_entry request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists SKUs for a given project and location. - # - # @overload list_skus(request, options = nil) - # Pass arguments to `list_skus` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_skus(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_skus` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list SKUs in. - # Format: `projects/{project}/locations/{location}` - # - # To list SKUs across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new - # - # # Call the list_skus method. - # result = client.list_skus request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - # p item - # end - # - def list_skus request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_skus.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_skus.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_skus.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_skus request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_skus, "skus", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of an SKU. - # - # @overload get_sku(request, options = nil) - # Pass arguments to `get_sku` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_sku(name: nil) - # Pass arguments to `get_sku` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the SKU. - # Format: `projects/{project}/locations/{location}/skus/{sku}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new - # - # # Call the get_sku method. - # result = client.get_sku request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - # p result - # - def get_sku request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_sku.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_sku.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_sku.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_sku request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Lists zones in a given project and location. - # - # @overload list_zones(request, options = nil) - # Pass arguments to `list_zones` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_zones(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) - # Pass arguments to `list_zones` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to list zones in. - # Format: `projects/{project}/locations/{location}` - # - # To list zones across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @param page_size [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @param page_token [::String] - # Optional. A token identifying a page of results the server should return. - # @param filter [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @param order_by [::String] - # Optional. Hint for how to order the results. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new - # - # # Call the list_zones method. - # result = client.list_zones request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - # p item - # end - # - def list_zones request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_zones.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_zones.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_zones.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.list_zones request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @gdc_hardware_management_stub, :list_zones, "zones", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets details of a zone. - # - # @overload get_zone(request, options = nil) - # Pass arguments to `get_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_zone(name: nil) - # Pass arguments to `get_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new - # - # # Call the get_zone method. - # result = client.get_zone request - # - # # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - # p result - # - def get_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_zone.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.get_zone request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Creates a new zone in a given project and location. - # - # @overload create_zone(request, options = nil) - # Pass arguments to `create_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload create_zone(parent: nil, zone_id: nil, zone: nil, request_id: nil) - # Pass arguments to `create_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param parent [::String] - # Required. The project and location to create the zone in. - # Format: `projects/{project}/locations/{location}` - # @param zone_id [::String] - # Optional. ID used to uniquely identify the Zone within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The zone.name field in the request will be ignored. - # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] - # Required. The zone to create. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new - # - # # Call the create_zone method. - # result = client.create_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def create_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.create_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.create_zone.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.create_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.create_zone request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the parameters of a zone. - # - # @overload update_zone(request, options = nil) - # Pass arguments to `update_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload update_zone(update_mask: nil, zone: nil, request_id: nil) - # Pass arguments to `update_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param update_mask [::Google::Protobuf::FieldMask, ::Hash] - # Required. A mask to specify the fields in the Zone to overwrite with this - # update. The fields specified in the update_mask are relative to the zone, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @param zone [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone, ::Hash] - # Required. The zone to update. - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new - # - # # Call the update_zone method. - # result = client.update_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def update_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.update_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.update_zone.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.update_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.update_zone request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a zone. - # - # @overload delete_zone(request, options = nil) - # Pass arguments to `delete_zone` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_zone(name: nil, request_id: nil) - # Pass arguments to `delete_zone` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new - # - # # Call the delete_zone method. - # result = client.delete_zone request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def delete_zone request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_zone.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_zone.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_zone.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.delete_zone request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Signals the state of a zone. - # - # @overload signal_zone_state(request, options = nil) - # Pass arguments to `signal_zone_state` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload signal_zone_state(name: nil, request_id: nil, state_signal: nil, provisioning_state_signal: nil, step: nil, details: nil) - # Pass arguments to `signal_zone_state` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @param request_id [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @param state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] - # Optional. The state signal to send for this zone. Either state_signal or - # provisioning_state_signal must be set, but not both. - # @param provisioning_state_signal [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] - # Optional. The provisioning state signal to send for this zone. Either - # state_signal or provisioning_state_signal must be set, but not both. - # @param step [::String] - # Optional. The step being executed. Provides a finer grained status when the - # state_signal is FACTORY_TURNUP_CHECKS_STARTED or - # FACTORY_TURNUP_CHECKS_FAILED. - # @param details [::String] - # Optional. Additional details, such as an error message when state_signal is - # FACTORY_TURNUP_CHECKS_FAILED. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new - # - # # Call the signal_zone_state method. - # result = client.signal_zone_state request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def signal_zone_state request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.signal_zone_state.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.signal_zone_state.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.signal_zone_state.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.signal_zone_state request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Updates the requested date change of a single Order. - # - # @overload request_order_date_change(request, options = nil) - # Pass arguments to `request_order_date_change` via a request object, either of type - # {::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest} or an equivalent Hash. - # - # @param request [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload request_order_date_change(name: nil, requested_date: nil) - # Pass arguments to `request_order_date_change` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # Required. The name of the order to update. - # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} - # @param requested_date [::Google::Type::Date, ::Hash] - # Required. The date to which the customer or Google wants to set the - # scheduled installation date. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/cloud/gdc_hardware_management/v1alpha" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new - # - # # Call the request_order_date_change method. - # result = client.request_order_date_change request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def request_order_date_change request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.request_order_date_change.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.request_order_date_change.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.request_order_date_change.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @gdc_hardware_management_stub.request_order_date_change request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Configuration class for the GDCHardwareManagement REST API. - # - # This class represents the configuration for GDCHardwareManagement REST, - # providing control over timeouts, retry behavior, logging, transport - # parameters, and other low-level controls. Certain parameters can also be - # applied individually to specific RPCs. See - # {::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration::Rpcs} - # for a list of RPCs that can be configured independently. - # - # Configuration can be applied globally to all clients, or to a single client - # on construction. - # - # @example - # - # # Modify the global config, setting the timeout for - # # list_orders to 20 seconds, - # # and all remaining timeouts to 10 seconds. - # ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.configure do |config| - # config.timeout = 10.0 - # config.rpcs.list_orders.timeout = 20.0 - # end - # - # # Apply the above configuration only to a new client. - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - # config.timeout = 10.0 - # config.rpcs.list_orders.timeout = 20.0 - # end - # - # @!attribute [rw] endpoint - # A custom service endpoint, as a hostname or hostname:port. The default is - # nil, indicating to use the default endpoint in the current universe domain. - # @return [::String,nil] - # @!attribute [rw] credentials - # Credentials to send with calls. You may provide any of the following types: - # * (`String`) The path to a service account key file in JSON format - # * (`Hash`) A service account key as a Hash - # * (`Google::Auth::Credentials`) A googleauth credentials object - # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) - # * (`Signet::OAuth2::Client`) A signet oauth2 client object - # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) - # * (`nil`) indicating no credentials - # - # Warning: If you accept a credential configuration (JSON file or Hash) from an - # external source for authentication to Google Cloud, you must validate it before - # providing it to a Google API client library. Providing an unvalidated credential - # configuration to Google APIs can compromise the security of your systems and data. - # For more information, refer to [Validate credential configurations from external - # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). - # @return [::Object] - # @!attribute [rw] scope - # The OAuth scopes - # @return [::Array<::String>] - # @!attribute [rw] lib_name - # The library name as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] lib_version - # The library version as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] timeout - # The call timeout in seconds. - # @return [::Numeric] - # @!attribute [rw] metadata - # Additional headers to be sent with the call. - # @return [::Hash{::Symbol=>::String}] - # @!attribute [rw] retry_policy - # The retry policy. The value is a hash with the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # @return [::Hash] - # @!attribute [rw] quota_project - # A separate project against which to charge quota. - # @return [::String] - # @!attribute [rw] universe_domain - # The universe domain within which to make requests. This determines the - # default endpoint URL. The default value of nil uses the environment - # universe (usually the default "googleapis.com" universe). - # @return [::String,nil] - # @!attribute [rw] logger - # A custom logger to use for request/response debug logging, or the value - # `:default` (the default) to construct a default logger, or `nil` to - # explicitly disable logging. - # @return [::Logger,:default,nil] - # - class Configuration - extend ::Gapic::Config - - # @private - # The endpoint specific to the default "googleapis.com" universe. Deprecated. - DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" - - config_attr :endpoint, nil, ::String, nil - config_attr :credentials, nil do |value| - allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] - allowed.any? { |klass| klass === value } - end - config_attr :scope, nil, ::String, ::Array, nil - config_attr :lib_name, nil, ::String, nil - config_attr :lib_version, nil, ::String, nil - config_attr :timeout, nil, ::Numeric, nil - config_attr :metadata, nil, ::Hash, nil - config_attr :retry_policy, nil, ::Hash, ::Proc, nil - config_attr :quota_project, nil, ::String, nil - config_attr :universe_domain, nil, ::String, nil - - # @private - # Overrides for http bindings for the RPCs of this service - # are only used when this service is used as mixin, and only - # by the host service. - # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}] - config_attr :bindings_override, {}, ::Hash, nil - config_attr :logger, :default, ::Logger, nil, :default - - # @private - def initialize parent_config = nil - @parent_config = parent_config unless parent_config.nil? - - yield self if block_given? - end - - ## - # Configurations for individual RPCs - # @return [Rpcs] - # - def rpcs - @rpcs ||= begin - parent_rpcs = nil - parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) - Rpcs.new parent_rpcs - end - end - - ## - # Configuration RPC class for the GDCHardwareManagement API. - # - # Includes fields providing the configuration for each RPC in this service. - # Each configuration object is of type `Gapic::Config::Method` and includes - # the following configuration fields: - # - # * `timeout` (*type:* `Numeric`) - The call timeout in seconds - # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers - # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields - # include the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # - class Rpcs - ## - # RPC-specific configuration for `list_orders` - # @return [::Gapic::Config::Method] - # - attr_reader :list_orders - ## - # RPC-specific configuration for `get_order` - # @return [::Gapic::Config::Method] - # - attr_reader :get_order - ## - # RPC-specific configuration for `create_order` - # @return [::Gapic::Config::Method] - # - attr_reader :create_order - ## - # RPC-specific configuration for `update_order` - # @return [::Gapic::Config::Method] - # - attr_reader :update_order - ## - # RPC-specific configuration for `delete_order` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_order - ## - # RPC-specific configuration for `submit_order` - # @return [::Gapic::Config::Method] - # - attr_reader :submit_order - ## - # RPC-specific configuration for `cancel_order` - # @return [::Gapic::Config::Method] - # - attr_reader :cancel_order - ## - # RPC-specific configuration for `list_sites` - # @return [::Gapic::Config::Method] - # - attr_reader :list_sites - ## - # RPC-specific configuration for `get_site` - # @return [::Gapic::Config::Method] - # - attr_reader :get_site - ## - # RPC-specific configuration for `create_site` - # @return [::Gapic::Config::Method] - # - attr_reader :create_site - ## - # RPC-specific configuration for `update_site` - # @return [::Gapic::Config::Method] - # - attr_reader :update_site - ## - # RPC-specific configuration for `delete_site` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_site - ## - # RPC-specific configuration for `list_hardware_groups` - # @return [::Gapic::Config::Method] - # - attr_reader :list_hardware_groups - ## - # RPC-specific configuration for `get_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :get_hardware_group - ## - # RPC-specific configuration for `create_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :create_hardware_group - ## - # RPC-specific configuration for `update_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :update_hardware_group - ## - # RPC-specific configuration for `delete_hardware_group` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_hardware_group - ## - # RPC-specific configuration for `list_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :list_hardware - ## - # RPC-specific configuration for `get_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :get_hardware - ## - # RPC-specific configuration for `create_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :create_hardware - ## - # RPC-specific configuration for `update_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :update_hardware - ## - # RPC-specific configuration for `delete_hardware` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_hardware - ## - # RPC-specific configuration for `list_comments` - # @return [::Gapic::Config::Method] - # - attr_reader :list_comments - ## - # RPC-specific configuration for `get_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :get_comment - ## - # RPC-specific configuration for `create_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :create_comment - ## - # RPC-specific configuration for `record_action_on_comment` - # @return [::Gapic::Config::Method] - # - attr_reader :record_action_on_comment - ## - # RPC-specific configuration for `list_change_log_entries` - # @return [::Gapic::Config::Method] - # - attr_reader :list_change_log_entries - ## - # RPC-specific configuration for `get_change_log_entry` - # @return [::Gapic::Config::Method] - # - attr_reader :get_change_log_entry - ## - # RPC-specific configuration for `list_skus` - # @return [::Gapic::Config::Method] - # - attr_reader :list_skus - ## - # RPC-specific configuration for `get_sku` - # @return [::Gapic::Config::Method] - # - attr_reader :get_sku - ## - # RPC-specific configuration for `list_zones` - # @return [::Gapic::Config::Method] - # - attr_reader :list_zones - ## - # RPC-specific configuration for `get_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :get_zone - ## - # RPC-specific configuration for `create_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :create_zone - ## - # RPC-specific configuration for `update_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :update_zone - ## - # RPC-specific configuration for `delete_zone` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_zone - ## - # RPC-specific configuration for `signal_zone_state` - # @return [::Gapic::Config::Method] - # - attr_reader :signal_zone_state - ## - # RPC-specific configuration for `request_order_date_change` - # @return [::Gapic::Config::Method] - # - attr_reader :request_order_date_change - - # @private - def initialize parent_rpcs = nil - list_orders_config = parent_rpcs.list_orders if parent_rpcs.respond_to? :list_orders - @list_orders = ::Gapic::Config::Method.new list_orders_config - get_order_config = parent_rpcs.get_order if parent_rpcs.respond_to? :get_order - @get_order = ::Gapic::Config::Method.new get_order_config - create_order_config = parent_rpcs.create_order if parent_rpcs.respond_to? :create_order - @create_order = ::Gapic::Config::Method.new create_order_config - update_order_config = parent_rpcs.update_order if parent_rpcs.respond_to? :update_order - @update_order = ::Gapic::Config::Method.new update_order_config - delete_order_config = parent_rpcs.delete_order if parent_rpcs.respond_to? :delete_order - @delete_order = ::Gapic::Config::Method.new delete_order_config - submit_order_config = parent_rpcs.submit_order if parent_rpcs.respond_to? :submit_order - @submit_order = ::Gapic::Config::Method.new submit_order_config - cancel_order_config = parent_rpcs.cancel_order if parent_rpcs.respond_to? :cancel_order - @cancel_order = ::Gapic::Config::Method.new cancel_order_config - list_sites_config = parent_rpcs.list_sites if parent_rpcs.respond_to? :list_sites - @list_sites = ::Gapic::Config::Method.new list_sites_config - get_site_config = parent_rpcs.get_site if parent_rpcs.respond_to? :get_site - @get_site = ::Gapic::Config::Method.new get_site_config - create_site_config = parent_rpcs.create_site if parent_rpcs.respond_to? :create_site - @create_site = ::Gapic::Config::Method.new create_site_config - update_site_config = parent_rpcs.update_site if parent_rpcs.respond_to? :update_site - @update_site = ::Gapic::Config::Method.new update_site_config - delete_site_config = parent_rpcs.delete_site if parent_rpcs.respond_to? :delete_site - @delete_site = ::Gapic::Config::Method.new delete_site_config - list_hardware_groups_config = parent_rpcs.list_hardware_groups if parent_rpcs.respond_to? :list_hardware_groups - @list_hardware_groups = ::Gapic::Config::Method.new list_hardware_groups_config - get_hardware_group_config = parent_rpcs.get_hardware_group if parent_rpcs.respond_to? :get_hardware_group - @get_hardware_group = ::Gapic::Config::Method.new get_hardware_group_config - create_hardware_group_config = parent_rpcs.create_hardware_group if parent_rpcs.respond_to? :create_hardware_group - @create_hardware_group = ::Gapic::Config::Method.new create_hardware_group_config - update_hardware_group_config = parent_rpcs.update_hardware_group if parent_rpcs.respond_to? :update_hardware_group - @update_hardware_group = ::Gapic::Config::Method.new update_hardware_group_config - delete_hardware_group_config = parent_rpcs.delete_hardware_group if parent_rpcs.respond_to? :delete_hardware_group - @delete_hardware_group = ::Gapic::Config::Method.new delete_hardware_group_config - list_hardware_config = parent_rpcs.list_hardware if parent_rpcs.respond_to? :list_hardware - @list_hardware = ::Gapic::Config::Method.new list_hardware_config - get_hardware_config = parent_rpcs.get_hardware if parent_rpcs.respond_to? :get_hardware - @get_hardware = ::Gapic::Config::Method.new get_hardware_config - create_hardware_config = parent_rpcs.create_hardware if parent_rpcs.respond_to? :create_hardware - @create_hardware = ::Gapic::Config::Method.new create_hardware_config - update_hardware_config = parent_rpcs.update_hardware if parent_rpcs.respond_to? :update_hardware - @update_hardware = ::Gapic::Config::Method.new update_hardware_config - delete_hardware_config = parent_rpcs.delete_hardware if parent_rpcs.respond_to? :delete_hardware - @delete_hardware = ::Gapic::Config::Method.new delete_hardware_config - list_comments_config = parent_rpcs.list_comments if parent_rpcs.respond_to? :list_comments - @list_comments = ::Gapic::Config::Method.new list_comments_config - get_comment_config = parent_rpcs.get_comment if parent_rpcs.respond_to? :get_comment - @get_comment = ::Gapic::Config::Method.new get_comment_config - create_comment_config = parent_rpcs.create_comment if parent_rpcs.respond_to? :create_comment - @create_comment = ::Gapic::Config::Method.new create_comment_config - record_action_on_comment_config = parent_rpcs.record_action_on_comment if parent_rpcs.respond_to? :record_action_on_comment - @record_action_on_comment = ::Gapic::Config::Method.new record_action_on_comment_config - list_change_log_entries_config = parent_rpcs.list_change_log_entries if parent_rpcs.respond_to? :list_change_log_entries - @list_change_log_entries = ::Gapic::Config::Method.new list_change_log_entries_config - get_change_log_entry_config = parent_rpcs.get_change_log_entry if parent_rpcs.respond_to? :get_change_log_entry - @get_change_log_entry = ::Gapic::Config::Method.new get_change_log_entry_config - list_skus_config = parent_rpcs.list_skus if parent_rpcs.respond_to? :list_skus - @list_skus = ::Gapic::Config::Method.new list_skus_config - get_sku_config = parent_rpcs.get_sku if parent_rpcs.respond_to? :get_sku - @get_sku = ::Gapic::Config::Method.new get_sku_config - list_zones_config = parent_rpcs.list_zones if parent_rpcs.respond_to? :list_zones - @list_zones = ::Gapic::Config::Method.new list_zones_config - get_zone_config = parent_rpcs.get_zone if parent_rpcs.respond_to? :get_zone - @get_zone = ::Gapic::Config::Method.new get_zone_config - create_zone_config = parent_rpcs.create_zone if parent_rpcs.respond_to? :create_zone - @create_zone = ::Gapic::Config::Method.new create_zone_config - update_zone_config = parent_rpcs.update_zone if parent_rpcs.respond_to? :update_zone - @update_zone = ::Gapic::Config::Method.new update_zone_config - delete_zone_config = parent_rpcs.delete_zone if parent_rpcs.respond_to? :delete_zone - @delete_zone = ::Gapic::Config::Method.new delete_zone_config - signal_zone_state_config = parent_rpcs.signal_zone_state if parent_rpcs.respond_to? :signal_zone_state - @signal_zone_state = ::Gapic::Config::Method.new signal_zone_state_config - request_order_date_change_config = parent_rpcs.request_order_date_change if parent_rpcs.respond_to? :request_order_date_change - @request_order_date_change = ::Gapic::Config::Method.new request_order_date_change_config - - yield self if block_given? - end - end - end - end - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb deleted file mode 100644 index 0fd6460e36ea..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/operations.rb +++ /dev/null @@ -1,925 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "gapic/operation" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - module Rest - # Service that implements Longrunning Operations API. - class Operations - # @private - API_VERSION = "" - - # @private - DEFAULT_ENDPOINT_TEMPLATE = "gdchardwaremanagement.$UNIVERSE_DOMAIN$" - - # @private - attr_reader :operations_stub - - ## - # Configuration for the GDCHardwareManagement Operations API. - # - # @yield [config] Configure the Operations client. - # @yieldparam config [Operations::Configuration] - # - # @return [Operations::Configuration] - # - def self.configure - @configure ||= Operations::Configuration.new - yield @configure if block_given? - @configure - end - - ## - # Configure the GDCHardwareManagement Operations instance. - # - # The configuration is set to the derived mode, meaning that values can be changed, - # but structural changes (adding new fields, etc.) are not allowed. Structural changes - # should be made on {Operations.configure}. - # - # @yield [config] Configure the Operations client. - # @yieldparam config [Operations::Configuration] - # - # @return [Operations::Configuration] - # - def configure - yield @config if block_given? - @config - end - - ## - # The effective universe domain - # - # @return [String] - # - def universe_domain - @operations_stub.universe_domain - end - - ## - # Create a new Operations client object. - # - # @yield [config] Configure the Client client. - # @yieldparam config [Operations::Configuration] - # - def initialize - # Create the configuration object - @config = Configuration.new Operations.configure - - # Yield the configuration if needed - yield @config if block_given? - - # Create credentials - credentials = @config.credentials - credentials ||= Credentials.default scope: @config.scope - if credentials.is_a?(::String) || credentials.is_a?(::Hash) - credentials = Credentials.new credentials, scope: @config.scope - end - - @quota_project_id = @config.quota_project - @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id - - @operations_stub = OperationsServiceStub.new( - endpoint: @config.endpoint, - endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, - universe_domain: @config.universe_domain, - credentials: credentials - ) - - # Used by an LRO wrapper for some methods of this service - @operations_client = self - end - - # Service calls - - ## - # Lists operations that match the specified filter in the request. If the - # server doesn't support this method, it returns `UNIMPLEMENTED`. - # - # @overload list_operations(request, options = nil) - # Pass arguments to `list_operations` via a request object, either of type - # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::ListOperationsRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload list_operations(name: nil, filter: nil, page_size: nil, page_token: nil, return_partial_success: nil) - # Pass arguments to `list_operations` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation's parent resource. - # @param filter [::String] - # The standard list filter. - # @param page_size [::Integer] - # The standard list page size. - # @param page_token [::String] - # The standard list page token. - # @param return_partial_success [::Boolean] - # When set to `true`, operations that are reachable are returned as normal, - # and those that are unreachable are returned in the - # [ListOperationsResponse.unreachable] field. - # - # This can only be `true` when reading across collections e.g. when `parent` - # is set to `"projects/example/locations/-"`. - # - # This field is not by default supported and will result in an - # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in - # service or product specific documentation. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::ListOperationsRequest.new - # - # # Call the list_operations method. - # result = client.list_operations request - # - # # The returned object is of type Gapic::PagedEnumerable. You can iterate - # # over elements, and API calls will be issued to fetch pages as needed. - # result.each do |item| - # # Each element is of type ::Google::Longrunning::Operation. - # p item - # end - # - def list_operations request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::ListOperationsRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.list_operations.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.list_operations.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.list_operations.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.list_operations request, options do |result, operation| - result = ::Gapic::Rest::PagedEnumerable.new @operations_stub, :list_operations, "operations", request, result, options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Gets the latest state of a long-running operation. Clients can use this - # method to poll the operation result at intervals as recommended by the API - # service. - # - # @overload get_operation(request, options = nil) - # Pass arguments to `get_operation` via a request object, either of type - # {::Google::Longrunning::GetOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::GetOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload get_operation(name: nil) - # Pass arguments to `get_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Gapic::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Gapic::Operation] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::GetOperationRequest.new - # - # # Call the get_operation method. - # result = client.get_operation request - # - # # The returned object is of type Gapic::Operation. You can use it to - # # check the status of an operation, cancel it, or wait for results. - # # Here is how to wait for a response. - # result.wait_until_done! timeout: 60 - # if result.response? - # p result.response - # else - # puts "No response received." - # end - # - def get_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::GetOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.get_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.get_operation.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.get_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.get_operation request, options do |result, operation| - result = ::Gapic::Operation.new result, @operations_client, options: options - yield result, operation if block_given? - throw :response, result - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Deletes a long-running operation. This method indicates that the client is - # no longer interested in the operation result. It does not cancel the - # operation. If the server doesn't support this method, it returns - # `google.rpc.Code.UNIMPLEMENTED`. - # - # @overload delete_operation(request, options = nil) - # Pass arguments to `delete_operation` via a request object, either of type - # {::Google::Longrunning::DeleteOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::DeleteOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload delete_operation(name: nil) - # Pass arguments to `delete_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource to be deleted. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Protobuf::Empty] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Protobuf::Empty] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::DeleteOperationRequest.new - # - # # Call the delete_operation method. - # result = client.delete_operation request - # - # # The returned object is of type Google::Protobuf::Empty. - # p result - # - def delete_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::DeleteOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.delete_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.delete_operation.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.delete_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.delete_operation request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Starts asynchronous cancellation on a long-running operation. The server - # makes a best effort to cancel the operation, but success is not - # guaranteed. If the server doesn't support this method, it returns - # `google.rpc.Code.UNIMPLEMENTED`. Clients can use - # Operations.GetOperation or - # other methods to check whether the cancellation succeeded or whether the - # operation completed despite cancellation. On successful cancellation, - # the operation is not deleted; instead, it becomes an operation with - # an {::Google::Longrunning::Operation#error Operation.error} value with a - # {::Google::Rpc::Status#code google.rpc.Status.code} of `1`, corresponding to - # `Code.CANCELLED`. - # - # @overload cancel_operation(request, options = nil) - # Pass arguments to `cancel_operation` via a request object, either of type - # {::Google::Longrunning::CancelOperationRequest} or an equivalent Hash. - # - # @param request [::Google::Longrunning::CancelOperationRequest, ::Hash] - # A request object representing the call parameters. Required. To specify no - # parameters, or to keep all the default parameter values, pass an empty Hash. - # @param options [::Gapic::CallOptions, ::Hash] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @overload cancel_operation(name: nil) - # Pass arguments to `cancel_operation` via keyword arguments. Note that at - # least one keyword argument is required. To specify no parameters, or to keep all - # the default parameter values, pass an empty Hash as a request object (see above). - # - # @param name [::String] - # The name of the operation resource to be cancelled. - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Protobuf::Empty] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Protobuf::Empty] - # - # @raise [::Google::Cloud::Error] if the REST call is aborted. - # - # @example Basic example - # require "google/longrunning" - # - # # Create a client object. The client can be reused for multiple calls. - # client = Google::Longrunning::Operations::Rest::Client.new - # - # # Create a request. To set request fields, pass in keyword arguments. - # request = Google::Longrunning::CancelOperationRequest.new - # - # # Call the cancel_operation method. - # result = client.cancel_operation request - # - # # The returned object is of type Google::Protobuf::Empty. - # p result - # - def cancel_operation request, options = nil - raise ::ArgumentError, "request must be provided" if request.nil? - - request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::CancelOperationRequest - - # Converts hash and nil to an options object - options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h - - # Customize the options with defaults - call_metadata = @config.rpcs.cancel_operation.metadata.to_h - - # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers - call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ - lib_name: @config.lib_name, lib_version: @config.lib_version, - gapic_version: ::Google::Cloud::GDCHardwareManagement::V1alpha::VERSION, - transports_version_send: [:rest] - - call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? - call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id - - options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout, - metadata: call_metadata, - retry_policy: @config.rpcs.cancel_operation.retry_policy - - options.apply_defaults timeout: @config.timeout, - metadata: @config.metadata, - retry_policy: @config.retry_policy - - @operations_stub.cancel_operation request, options do |result, operation| - yield result, operation if block_given? - end - rescue ::Gapic::Rest::Error => e - raise ::Google::Cloud::Error.from_error(e) - end - - ## - # Configuration class for the Operations REST API. - # - # This class represents the configuration for Operations REST, - # providing control over timeouts, retry behavior, logging, transport - # parameters, and other low-level controls. Certain parameters can also be - # applied individually to specific RPCs. See - # {::Google::Longrunning::Operations::Rest::Client::Configuration::Rpcs} - # for a list of RPCs that can be configured independently. - # - # Configuration can be applied globally to all clients, or to a single client - # on construction. - # - # @example - # - # # Modify the global config, setting the timeout for - # # list_operations to 20 seconds, - # # and all remaining timeouts to 10 seconds. - # ::Google::Longrunning::Operations::Rest::Client.configure do |config| - # config.timeout = 10.0 - # config.rpcs.list_operations.timeout = 20.0 - # end - # - # # Apply the above configuration only to a new client. - # client = ::Google::Longrunning::Operations::Rest::Client.new do |config| - # config.timeout = 10.0 - # config.rpcs.list_operations.timeout = 20.0 - # end - # - # @!attribute [rw] endpoint - # A custom service endpoint, as a hostname or hostname:port. The default is - # nil, indicating to use the default endpoint in the current universe domain. - # @return [::String,nil] - # @!attribute [rw] credentials - # Credentials to send with calls. You may provide any of the following types: - # * (`String`) The path to a service account key file in JSON format - # * (`Hash`) A service account key as a Hash - # * (`Google::Auth::Credentials`) A googleauth credentials object - # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) - # * (`Signet::OAuth2::Client`) A signet oauth2 client object - # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) - # * (`nil`) indicating no credentials - # - # Warning: If you accept a credential configuration (JSON file or Hash) from an - # external source for authentication to Google Cloud, you must validate it before - # providing it to a Google API client library. Providing an unvalidated credential - # configuration to Google APIs can compromise the security of your systems and data. - # For more information, refer to [Validate credential configurations from external - # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials). - # @return [::Object] - # @!attribute [rw] scope - # The OAuth scopes - # @return [::Array<::String>] - # @!attribute [rw] lib_name - # The library name as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] lib_version - # The library version as recorded in instrumentation and logging - # @return [::String] - # @!attribute [rw] timeout - # The call timeout in seconds. - # @return [::Numeric] - # @!attribute [rw] metadata - # Additional headers to be sent with the call. - # @return [::Hash{::Symbol=>::String}] - # @!attribute [rw] retry_policy - # The retry policy. The value is a hash with the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # @return [::Hash] - # @!attribute [rw] quota_project - # A separate project against which to charge quota. - # @return [::String] - # @!attribute [rw] universe_domain - # The universe domain within which to make requests. This determines the - # default endpoint URL. The default value of nil uses the environment - # universe (usually the default "googleapis.com" universe). - # @return [::String,nil] - # @!attribute [rw] logger - # A custom logger to use for request/response debug logging, or the value - # `:default` (the default) to construct a default logger, or `nil` to - # explicitly disable logging. - # @return [::Logger,:default,nil] - # - class Configuration - extend ::Gapic::Config - - # @private - # The endpoint specific to the default "googleapis.com" universe. Deprecated. - DEFAULT_ENDPOINT = "gdchardwaremanagement.googleapis.com" - - config_attr :endpoint, nil, ::String, nil - config_attr :credentials, nil do |value| - allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil] - allowed.any? { |klass| klass === value } - end - config_attr :scope, nil, ::String, ::Array, nil - config_attr :lib_name, nil, ::String, nil - config_attr :lib_version, nil, ::String, nil - config_attr :timeout, nil, ::Numeric, nil - config_attr :metadata, nil, ::Hash, nil - config_attr :retry_policy, nil, ::Hash, ::Proc, nil - config_attr :quota_project, nil, ::String, nil - config_attr :universe_domain, nil, ::String, nil - config_attr :logger, :default, ::Logger, nil, :default - - # @private - def initialize parent_config = nil - @parent_config = parent_config unless parent_config.nil? - - yield self if block_given? - end - - ## - # Configurations for individual RPCs - # @return [Rpcs] - # - def rpcs - @rpcs ||= begin - parent_rpcs = nil - parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) - Rpcs.new parent_rpcs - end - end - - ## - # Configuration RPC class for the Operations API. - # - # Includes fields providing the configuration for each RPC in this service. - # Each configuration object is of type `Gapic::Config::Method` and includes - # the following configuration fields: - # - # * `timeout` (*type:* `Numeric`) - The call timeout in seconds - # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers - # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields - # include the following keys: - # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. - # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. - # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. - # * `:retry_codes` (*type:* `Array`) - The error codes that should - # trigger a retry. - # - class Rpcs - ## - # RPC-specific configuration for `list_operations` - # @return [::Gapic::Config::Method] - # - attr_reader :list_operations - ## - # RPC-specific configuration for `get_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :get_operation - ## - # RPC-specific configuration for `delete_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :delete_operation - ## - # RPC-specific configuration for `cancel_operation` - # @return [::Gapic::Config::Method] - # - attr_reader :cancel_operation - - # @private - def initialize parent_rpcs = nil - list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations - @list_operations = ::Gapic::Config::Method.new list_operations_config - get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation - @get_operation = ::Gapic::Config::Method.new get_operation_config - delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation - @delete_operation = ::Gapic::Config::Method.new delete_operation_config - cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation - @cancel_operation = ::Gapic::Config::Method.new cancel_operation_config - - yield self if block_given? - end - end - end - end - - ## - # @private - # REST service stub for the Longrunning Operations API. - # Service stub contains baseline method implementations - # including transcoding, making the REST call, and deserialing the response. - class OperationsServiceStub - def initialize endpoint:, endpoint_template:, universe_domain:, credentials: - # These require statements are intentionally placed here to initialize - # the REST modules only when it's required. - require "gapic/rest" - - @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, - endpoint_template: endpoint_template, - universe_domain: universe_domain, - credentials: credentials - end - - ## - # Baseline implementation for the list_operations REST call - # - # @param request_pb [::Google::Longrunning::ListOperationsRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::ListOperationsResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::ListOperationsResponse] - # A result object deserialized from the server's reply - def list_operations request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = OperationsServiceStub.transcode_list_operations_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_operations", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::ListOperationsResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_operation REST call - # - # @param request_pb [::Google::Longrunning::GetOperationRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def get_operation request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = OperationsServiceStub.transcode_get_operation_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_operation", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_operation REST call - # - # @param request_pb [::Google::Longrunning::DeleteOperationRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Protobuf::Empty] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Protobuf::Empty] - # A result object deserialized from the server's reply - def delete_operation request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = OperationsServiceStub.transcode_delete_operation_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_operation", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the cancel_operation REST call - # - # @param request_pb [::Google::Longrunning::CancelOperationRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Protobuf::Empty] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Protobuf::Empty] - # A result object deserialized from the server's reply - def cancel_operation request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = OperationsServiceStub.transcode_cancel_operation_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "cancel_operation", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # @private - # - # GRPC transcoding helper method for the list_operations REST call - # - # @param request_pb [::Google::Longrunning::ListOperationsRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_operations_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}/operations", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_operation REST call - # - # @param request_pb [::Google::Longrunning::GetOperationRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_operation_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_operation REST call - # - # @param request_pb [::Google::Longrunning::DeleteOperationRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_operation_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the cancel_operation REST call - # - # @param request_pb [::Google::Longrunning::CancelOperationRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_cancel_operation_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:cancel", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - end - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb deleted file mode 100644 index 0f1cf309a507..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest/service_stub.rb +++ /dev/null @@ -1,2354 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - module Rest - ## - # REST service stub for the GDCHardwareManagement service. - # Service stub contains baseline method implementations - # including transcoding, making the REST call, and deserialing the response. - # - class ServiceStub - # @private - def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger: - # These require statements are intentionally placed here to initialize - # the REST modules only when it's required. - require "gapic/rest" - - @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, - endpoint_template: endpoint_template, - universe_domain: universe_domain, - credentials: credentials, - numeric_enums: true, - service_name: self.class, - raise_faraday_errors: false, - logger: logger - end - - ## - # The effective universe domain - # - # @return [String] - # - def universe_domain - @client_stub.universe_domain - end - - ## - # The effective endpoint - # - # @return [String] - # - def endpoint - @client_stub.endpoint - end - - ## - # The logger used for request/response debug logging. - # - # @return [Logger] - # - def logger stub: false - stub ? @client_stub.stub_logger : @client_stub.logger - end - - ## - # Baseline implementation for the list_orders REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse] - # A result object deserialized from the server's reply - def list_orders request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_orders_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_orders", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # A result object deserialized from the server's reply - def get_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the update_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def update_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_update_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "update_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def delete_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_delete_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the submit_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def submit_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_submit_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "submit_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the cancel_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def cancel_order request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_cancel_order_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "cancel_order", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_sites REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse] - # A result object deserialized from the server's reply - def list_sites request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_sites_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_sites", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # A result object deserialized from the server's reply - def get_site request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_site_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_site", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_site request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_site_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_site", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the update_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def update_site request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_update_site_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "update_site", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def delete_site request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_delete_site_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_site", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_hardware_groups REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse] - # A result object deserialized from the server's reply - def list_hardware_groups request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_hardware_groups_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_hardware_groups", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # A result object deserialized from the server's reply - def get_hardware_group request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_hardware_group_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_hardware_group", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_hardware_group request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_hardware_group_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_hardware_group", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the update_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def update_hardware_group request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_update_hardware_group_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "update_hardware_group", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def delete_hardware_group request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_delete_hardware_group_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_hardware_group", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse] - # A result object deserialized from the server's reply - def list_hardware request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_hardware_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_hardware", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # A result object deserialized from the server's reply - def get_hardware request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_hardware_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_hardware", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_hardware request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_hardware_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_hardware", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the update_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def update_hardware request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_update_hardware_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "update_hardware", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def delete_hardware request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_delete_hardware_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_hardware", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_comments REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse] - # A result object deserialized from the server's reply - def list_comments request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_comments_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_comments", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # A result object deserialized from the server's reply - def get_comment request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_comment_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_comment", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_comment request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_comment_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_comment", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the record_action_on_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # A result object deserialized from the server's reply - def record_action_on_comment request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_record_action_on_comment_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "record_action_on_comment", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_change_log_entries REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse] - # A result object deserialized from the server's reply - def list_change_log_entries request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_change_log_entries_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_change_log_entries", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_change_log_entry REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry] - # A result object deserialized from the server's reply - def get_change_log_entry request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_change_log_entry_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_change_log_entry", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_skus REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse] - # A result object deserialized from the server's reply - def list_skus request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_skus_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_skus", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_sku REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku] - # A result object deserialized from the server's reply - def get_sku request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_sku_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_sku", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the list_zones REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse] - # A result object deserialized from the server's reply - def list_zones request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_list_zones_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "list_zones", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the get_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # A result object deserialized from the server's reply - def get_zone request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_get_zone_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "get_zone", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the create_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def create_zone request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_create_zone_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "create_zone", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the update_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def update_zone request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_update_zone_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "update_zone", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the delete_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def delete_zone request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_delete_zone_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "delete_zone", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the signal_zone_state REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def signal_zone_state request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_signal_zone_state_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "signal_zone_state", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # Baseline implementation for the request_order_date_change REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest] - # A request object representing the call parameters. Required. - # @param options [::Gapic::CallOptions] - # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. - # - # @yield [result, operation] Access the result along with the TransportOperation object - # @yieldparam result [::Google::Longrunning::Operation] - # @yieldparam operation [::Gapic::Rest::TransportOperation] - # - # @return [::Google::Longrunning::Operation] - # A result object deserialized from the server's reply - def request_order_date_change request_pb, options = nil - raise ::ArgumentError, "request must be provided" if request_pb.nil? - - verb, uri, query_string_params, body = ServiceStub.transcode_request_order_date_change_request request_pb - query_string_params = if query_string_params.any? - query_string_params.to_h { |p| p.split "=", 2 } - else - {} - end - - response = @client_stub.make_http_request( - verb, - uri: uri, - body: body || "", - params: query_string_params, - method_name: "request_order_date_change", - options: options - ) - operation = ::Gapic::Rest::TransportOperation.new response - result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true - catch :response do - yield result, operation if block_given? - result - end - end - - ## - # @private - # - # GRPC transcoding helper method for the list_orders REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_orders_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/orders", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/orders", - body: "order", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the update_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_update_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :patch, - uri_template: "/v1alpha/{order.name}", - body: "order", - matches: [ - ["order.name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the submit_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_submit_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:submit", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the cancel_order REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_cancel_order_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:cancel", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_sites REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_sites_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/sites", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_site_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_site_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/sites", - body: "site", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the update_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_update_site_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :patch, - uri_template: "/v1alpha/{site.name}", - body: "site", - matches: [ - ["site.name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_site REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_site_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/sites/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_hardware_groups REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_hardware_groups_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/hardwareGroups", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_hardware_group_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_hardware_group_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/hardwareGroups", - body: "hardware_group", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the update_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_update_hardware_group_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :patch, - uri_template: "/v1alpha/{hardware_group.name}", - body: "hardware_group", - matches: [ - ["hardware_group.name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_hardware_group REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_hardware_group_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/hardwareGroups/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_hardware_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/hardware", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_hardware_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_hardware_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/hardware", - body: "hardware", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the update_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_update_hardware_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :patch, - uri_template: "/v1alpha/{hardware.name}", - body: "hardware", - matches: [ - ["hardware.name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_hardware REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_hardware_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/hardware/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_comments REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_comments_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/comments", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_comment_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/comments/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_comment_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/comments", - body: "comment", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the record_action_on_comment REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_record_action_on_comment_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:recordAction", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/comments/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_change_log_entries REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_change_log_entries_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/changeLogEntries", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_change_log_entry REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_change_log_entry_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/changeLogEntries/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_skus REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_skus_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/skus", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_sku REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_sku_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/skus/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the list_zones REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_list_zones_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{parent}/zones", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the get_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_get_zone_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :get, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the create_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_create_zone_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{parent}/zones", - body: "zone", - matches: [ - ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the update_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_update_zone_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :patch, - uri_template: "/v1alpha/{zone.name}", - body: "zone", - matches: [ - ["zone.name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the delete_zone REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_delete_zone_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :delete, - uri_template: "/v1alpha/{name}", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the signal_zone_state REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_signal_zone_state_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:signal", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/zones/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - - ## - # @private - # - # GRPC transcoding helper method for the request_order_date_change REST call - # - # @param request_pb [::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest] - # A request object representing the call parameters. Required. - # @return [Array(String, [String, nil], Hash{String => String})] - # Uri, Body, Query string parameters - def self.transcode_request_order_date_change_request request_pb - transcoder = Gapic::Rest::GrpcTranscoder.new - .with_bindings( - uri_method: :post, - uri_template: "/v1alpha/{name}:requestDateChange", - body: "*", - matches: [ - ["name", %r{^projects/[^/]+/locations/[^/]+/orders/[^/]+/?$}, false] - ] - ) - transcoder.transcode request_pb - end - end - end - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb deleted file mode 100644 index 30ef342103a5..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/rest.rb +++ /dev/null @@ -1,38 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" -require "google/cloud/gdc_hardware_management/v1alpha/bindings_override" -require "google/cloud/gdc_hardware_management/v1alpha/version" - -module Google - module Cloud - module GDCHardwareManagement - ## - # To load just the REST part of this package, including all its services, and instantiate a REST client: - # - # @example - # - # require "google/cloud/gdc_hardware_management/v1alpha/rest" - # client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new - # - module V1alpha - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb deleted file mode 100644 index b560b3e7f8df..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdc_hardware_management/v1alpha/version.rb +++ /dev/null @@ -1,28 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - VERSION = "0.0.1" - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb deleted file mode 100644 index ace5f72be29f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/resources_pb.rb +++ /dev/null @@ -1,99 +0,0 @@ -# frozen_string_literal: true -# Generated by the protocol buffer compiler. DO NOT EDIT! -# source: google/cloud/gdchardwaremanagement/v1alpha/resources.proto - -require 'google/protobuf' - -require 'google/api/field_behavior_pb' -require 'google/api/field_info_pb' -require 'google/api/resource_pb' -require 'google/protobuf/timestamp_pb' -require 'google/type/date_pb' -require 'google/type/datetime_pb' -require 'google/type/dayofweek_pb' -require 'google/type/postal_address_pb' -require 'google/type/timeofday_pb' - - -descriptor_data = "\n:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\x1a\x1agoogle/type/datetime.proto\x1a\x1bgoogle/type/dayofweek.proto\x1a google/type/postal_address.proto\x1a\x1bgoogle/type/timeofday.proto\"\xf6\x0f\n\x05Order\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\r \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12R\n\x06labels\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Order.LabelsEntryB\x03\xe0\x41\x01\x12K\n\x05state\x18\x05 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.Order.StateB\x03\xe0\x41\x03\x12\x62\n\x14organization_contact\x18\x06 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12\x1d\n\x10target_workloads\x18\x07 \x03(\tB\x03\xe0\x41\x01\x12 \n\x13\x63ustomer_motivation\x18\x08 \x01(\tB\x03\xe0\x41\x02\x12;\n\x10\x66ulfillment_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x05\x18\x01\xe0\x41\x01\x12\x44\n$customer_requested_installation_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x18\n\x0bregion_code\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x1b\n\x0eorder_form_uri\x18\x0b \x01(\tB\x03\xe0\x41\x03\x12I\n\x04type\x18\x0c \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Order.TypeB\x03\xe0\x41\x03\x12\x34\n\x0bsubmit_time\x18\x0e \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x0f \x01(\tB\x03\xe0\x41\x03\x12\\\n\x11\x65xisting_hardware\x18\x10 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.HardwareLocationB\x03\xe0\x41\x01\x12^\n\x0f\x64\x65ployment_type\x18\x12 \x01(\x0e\x32@.google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentTypeB\x03\xe0\x41\x03\x12\x38\n\x18\x61\x63tual_installation_date\x18\x13 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12;\n\x1b\x65stimated_installation_date\x18\x14 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x16 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x16\n\tmigration\x18\x17 \x01(\x08\x42\x03\xe0\x41\x01\x12\x36\n\raccepted_time\x18\x18 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x35\n\x15requested_date_change\x18\x19 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\x19\n\x0cvendor_notes\x18\x1a \x01(\tB\x03\xe0\x41\x03\x12\\\n\x0evendor_contact\x18\x1b \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xe4\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\t\n\x05\x44RAFT\x10\x01\x12\r\n\tSUBMITTED\x10\x02\x12\x11\n\rINFO_COMPLETE\x10\x0c\x12\x0c\n\x08\x41\x43\x43\x45PTED\x10\x03\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x04\x12\x0c\n\x08\x42UILDING\x10\x05\x12\x0c\n\x08SHIPPING\x10\x06\x12\x0e\n\nINSTALLING\x10\x07\x12\n\n\x06\x46\x41ILED\x10\x08\x12\x17\n\x13PARTIALLY_COMPLETED\x10\t\x12\r\n\tCOMPLETED\x10\n\x12\r\n\tCANCELLED\x10\x0b\"?\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04PAID\x10\x01\x12\x07\n\x03POC\x10\x02\x12\n\n\x06UNPAID\x10\x02\x1a\x02\x10\x01\"|\n\x0e\x44\x65ploymentType\x12\x1f\n\x1b\x44\x45PLOYMENT_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x46ULL_PRODUCTION\x10\x01\x12\x14\n\x10PROOF_OF_CONCEPT\x10\x02\x12\x0c\n\x08INTERNAL\x10\x03\x12\x10\n\x0c\x43USTOMER_LAB\x10\x04:v\xea\x41s\n*gdchardwaremanagement.googleapis.com/Order\x12\x36projects/{project}/locations/{location}/orders/{order}*\x06orders2\x05order\"\xbb\x05\n\x04Site\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x18 \x01(\tB\x03\xe0\x41\x01\x12\x18\n\x0b\x64\x65scription\x18\x19 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Site.LabelsEntryB\x03\xe0\x41\x01\x12\x62\n\x14organization_contact\x18\x05 \x01(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.OrganizationContactB\x03\xe0\x41\x02\x12 \n\x13google_maps_pin_uri\x18\x06 \x01(\tB\x03\xe0\x41\x01\x12Q\n\x0c\x61\x63\x63\x65ss_times\x18\x1a \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\x12\x12\n\x05notes\x18\x1b \x01(\tB\x03\xe0\x41\x01\x12\x1d\n\x10\x63ustomer_site_id\x18\x1c \x01(\tB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Site\x12\x34projects/{project}/locations/{location}/sites/{site}*\x05sites2\x04site\"\xec\x07\n\rHardwareGroup\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Z\n\x06labels\x18\x04 \x03(\x0b\x32\x45.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.LabelsEntryB\x03\xe0\x41\x01\x12\x1b\n\x0ehardware_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02\x12O\n\x06\x63onfig\x18\x06 \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12?\n\x04site\x18\x07 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12S\n\x05state\x18\x08 \x01(\x0e\x32?.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.StateB\x03\xe0\x41\x03\x12?\n\x04zone\x18\t \x01(\tB1\xe0\x41\x01\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12=\n\x1brequested_installation_date\x18\n \x01(\x0b\x32\x11.google.type.DateB\x05\x18\x01\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x9a\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\x17\n\x13PARTIALLY_INSTALLED\x10\x05\x12\r\n\tINSTALLED\x10\x06\x12\n\n\x06\x46\x41ILED\x10\x07:\xaf\x01\xea\x41\xab\x01\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12Vprojects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}*\x0ehardwareGroups2\rhardwareGroup\"\x99\x11\n\x08Hardware\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12U\n\x06labels\x18\x05 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.LabelsEntryB\x03\xe0\x41\x01\x12\x41\n\x05order\x18\x06 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12R\n\x0ehardware_group\x18\x07 \x01(\tB:\xe0\x41\x03\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12?\n\x04site\x18\x08 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12N\n\x05state\x18\t \x01(\x0e\x32:.google.cloud.gdchardwaremanagement.v1alpha.Hardware.StateB\x03\xe0\x41\x03\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12O\n\x06\x63onfig\x18\x0b \x01(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.HardwareConfigB\x03\xe0\x41\x02\x12;\n\x1b\x65stimated_installation_date\x18\x0c \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rphysical_info\x18\r \x01(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfoB\x03\xe0\x41\x01\x12\x64\n\x11installation_info\x18\x0e \x01(\x0b\x32\x44.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfoB\x03\xe0\x41\x01\x12?\n\x04zone\x18\x0f \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12;\n\x1brequested_installation_date\x18\x10 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x01\x12\x38\n\x18\x61\x63tual_installation_date\x18\x11 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x12\\\n\rmachine_infos\x18\x14 \x03(\x0b\x32@.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfoB\x03\xe0\x41\x03\x12\x37\n\x17\x65stimated_delivery_date\x18\x15 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x03\x1a\xf1\x01\n\nMacAddress\x12\x14\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12^\n\x04type\x18\x02 \x01(\x0e\x32K.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressTypeB\x03\xe0\x41\x03\x12!\n\x0cipv4_address\x18\x03 \x01(\tB\x0b\xe0\x41\x03\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"J\n\x0b\x41\x64\x64ressType\x12\x1c\n\x18\x41\x44\x44RESS_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03NIC\x10\x01\x12\x07\n\x03\x42MC\x10\x02\x12\x0b\n\x07VIRTUAL\x10\x03\x1a\x9c\x01\n\x08\x44iskInfo\x12\x19\n\x0cmanufacturer\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04slot\x18\x02 \x01(\x05\x42\x03\xe0\x41\x03\x12\x1a\n\rserial_number\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04psid\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0bpart_number\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cmodel_number\x18\x06 \x01(\tB\x03\xe0\x41\x03\x1a\xef\x01\n\x0bMachineInfo\x12\x18\n\x0bservice_tag\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12[\n\rmac_addresses\x18\x02 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddressB\x03\xe0\x41\x03\x12\x11\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12V\n\ndisk_infos\x18\x04 \x03(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfoB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x81\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\x0c\n\x08\x42UILDING\x10\x02\x12\x0c\n\x08SHIPPING\x10\x03\x12\x0e\n\nINSTALLING\x10\x04\x12\r\n\tINSTALLED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06:\x84\x01\xea\x41\x80\x01\n-gdchardwaremanagement.googleapis.com/Hardware\x12;projects/{project}/locations/{location}/hardware/{hardware}*\x08hardware2\x08hardware\"\xa1\x04\n\x07\x43omment\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12T\n\x06labels\x18\x03 \x03(\x0b\x32?.google.cloud.gdchardwaremanagement.v1alpha.Comment.LabelsEntryB\x03\xe0\x41\x01\x12\x13\n\x06\x61uthor\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04text\x18\x05 \x01(\tB\x03\xe0\x41\x02\x12=\n\x14\x63ustomer_viewed_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12N\n\rauthor_entity\x18\x07 \x01(\x0e\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.EntityB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\x90\x01\xea\x41\x8c\x01\n,gdchardwaremanagement.googleapis.com/Comment\x12Iprojects/{project}/locations/{location}/orders/{order}/comments/{comment}*\x08\x63omments2\x07\x63omment\"\xb1\x03\n\x0e\x43hangeLogEntry\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12[\n\x06labels\x18\x03 \x03(\x0b\x32\x46.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry.LabelsEntryB\x03\xe0\x41\x01\x12\x10\n\x03log\x18\x04 \x01(\tB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xb7\x01\xea\x41\xb3\x01\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12Zprojects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}*\x10\x63hangeLogEntries2\x0e\x63hangeLogEntry\"\x8a\x06\n\x03Sku\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12J\n\x06\x63onfig\x18\x06 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.SkuConfigB\x03\xe0\x41\x03\x12O\n\tinstances\x18\x07 \x03(\x0b\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.SkuInstanceB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x65scription\x18\x08 \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0brevision_id\x18\t \x01(\tB\x03\xe0\x41\x03\x12\x16\n\tis_active\x18\n \x01(\x08\x42\x03\xe0\x41\x03\x12G\n\x04type\x18\x0b \x01(\x0e\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Sku.TypeB\x03\xe0\x41\x03\x12\x17\n\nvcpu_count\x18\x0c \x01(\x05\x42\x03\xe0\x41\x03\x12Y\n\x15hardware_count_ranges\x18\r \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.Sku.RangeB\x03\xe0\x41\x03\x1a!\n\x05Range\x12\x0b\n\x03min\x18\x01 \x01(\x05\x12\x0b\n\x03max\x18\x02 \x01(\x05\"2\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04RACK\x10\x01\x12\n\n\x06SERVER\x10\x02:l\xea\x41i\n(gdchardwaremanagement.googleapis.com/Sku\x12\x32projects/{project}/locations/{location}/skus/{sku}*\x04skus2\x03sku\"\x9e\x0b\n\x04Zone\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x34\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Q\n\x06labels\x18\x04 \x03(\x0b\x32<.google.cloud.gdchardwaremanagement.v1alpha.Zone.LabelsEntryB\x03\xe0\x41\x01\x12\x19\n\x0c\x64isplay_name\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12J\n\x05state\x18\x08 \x01(\x0e\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.Zone.StateB\x03\xe0\x41\x03\x12J\n\x08\x63ontacts\x18\t \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\x12\x14\n\x07\x63iq_uri\x18\n \x01(\tB\x03\xe0\x41\x03\x12Z\n\x0enetwork_config\x18\x0b \x01(\x0b\x32=.google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfigB\x03\xe0\x41\x01\x12\x1f\n\x12globally_unique_id\x18\x0c \x01(\tB\x03\xe0\x41\x03\x12\x61\n\x14subscription_configs\x18\r \x03(\x0b\x32>.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfigB\x03\xe0\x41\x03\x12\x63\n\x12provisioning_state\x18\x0e \x01(\x0e\x32\x42.google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningStateB\x03\xe0\x41\x03\x12&\n\x19skip_cluster_provisioning\x18\x10 \x01(\x08\x42\x03\xe0\x41\x01\x12$\n\x17\x63luster_intent_required\x18\x11 \x01(\x08\x42\x03\xe0\x41\x03\x12$\n\x17\x63luster_intent_verified\x18\x12 \x01(\x08\x42\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x91\x02\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x41\x44\x44ITIONAL_INFO_NEEDED\x10\x01\x12\r\n\tPREPARING\x10\x02\x12,\n(READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS\x10\x05\x12*\n&CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED\x10\x08\x12\x19\n\x15READY_FOR_SITE_TURNUP\x10\x06\x12\x0b\n\x07OFFLINE\x10\t\x12)\n%CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED\x10\x07\x12\n\n\x06\x41\x43TIVE\x10\x03\x12\r\n\tCANCELLED\x10\x04\"\x8b\x01\n\x11ProvisioningState\x12\"\n\x1ePROVISIONING_STATE_UNSPECIFIED\x10\x00\x12\x19\n\x15PROVISIONING_REQUIRED\x10\x01\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x02\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x03:q\xea\x41n\n)gdchardwaremanagement.googleapis.com/Zone\x12\x34projects/{project}/locations/{location}/zones/{zone}*\x05zones2\x04zone\"\xbb\x01\n\x13OrganizationContact\x12\x30\n\x07\x61\x64\x64ress\x18\x01 \x01(\x0b\x32\x1a.google.type.PostalAddressB\x03\xe0\x41\x02\x12\x12\n\x05\x65mail\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05phone\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12J\n\x08\x63ontacts\x18\x04 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.ContactB\x03\xe0\x41\x02\"\xe9\x01\n\x07\x43ontact\x12\x17\n\ngiven_name\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\x18\n\x0b\x66\x61mily_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x65mail\x18\x03 \x01(\tB\x03\xe0\x41\x02\x12\x12\n\x05phone\x18\x04 \x01(\tB\x03\xe0\x41\x02\x12-\n\ttime_zone\x18\x05 \x01(\x0b\x32\x15.google.type.TimeZoneB\x03\xe0\x41\x01\x12T\n\x0freachable_times\x18\x06 \x03(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.TimePeriodB\x03\xe0\x41\x01\"\xce\x01\n\x0eHardwareConfig\x12=\n\x03sku\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\x12R\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupplyB\x03\xe0\x41\x02\x12)\n\x1csubscription_duration_months\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\"C\n\tSkuConfig\x12\x0b\n\x03\x63pu\x18\x01 \x01(\t\x12\x0b\n\x03gpu\x18\x02 \x01(\t\x12\x0b\n\x03ram\x18\x03 \x01(\t\x12\x0f\n\x07storage\x18\x04 \x01(\t\"\xca\x01\n\x0bSkuInstance\x12\x13\n\x0bregion_code\x18\x01 \x01(\t\x12M\n\x0cpower_supply\x18\x02 \x01(\x0e\x32\x37.google.cloud.gdchardwaremanagement.v1alpha.PowerSupply\x12\x13\n\x0b\x62illing_sku\x18\x03 \x01(\t\x12\x1c\n\x14\x62illing_sku_per_vcpu\x18\x04 \x01(\t\x12$\n\x1csubscription_duration_months\x18\x05 \x01(\x05\"\xa1\x06\n\x14HardwarePhysicalInfo\x12s\n\x10power_receptacle\x18\x01 \x01(\x0e\x32T.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleTypeB\x03\xe0\x41\x02\x12o\n\x0enetwork_uplink\x18\x02 \x01(\x0e\x32R.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkTypeB\x03\xe0\x41\x02\x12^\n\x07voltage\x18\x03 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.VoltageB\x03\xe0\x41\x02\x12^\n\x07\x61mperes\x18\x04 \x01(\x0e\x32H.google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.AmperesB\x03\xe0\x41\x02\"\xa3\x01\n\x13PowerReceptacleType\x12%\n!POWER_RECEPTACLE_TYPE_UNSPECIFIED\x10\x00\x12\r\n\tNEMA_5_15\x10\x01\x12\x08\n\x04\x43_13\x10\x02\x12\x13\n\x0bSTANDARD_EU\x10\x03\x1a\x02\x08\x01\x12\x11\n\rTYPE_G_BS1363\x10\x04\x12\x0b\n\x07\x43\x45\x45_7_3\x10\x05\x12\x0b\n\x07\x43\x45\x45_7_5\x10\x06\x12\n\n\x06TYPE_F\x10\x07\"C\n\x11NetworkUplinkType\x12#\n\x1fNETWORK_UPLINK_TYPE_UNSPECIFIED\x10\x00\x12\t\n\x05RJ_45\x10\x01\"D\n\x07Voltage\x12\x17\n\x13VOLTAGE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bVOLTAGE_110\x10\x01\x12\x0f\n\x0bVOLTAGE_220\x10\x03\"2\n\x07\x41mperes\x12\x17\n\x13\x41MPERES_UNSPECIFIED\x10\x00\x12\x0e\n\nAMPERES_15\x10\x01\"\xd5\x03\n\x18HardwareInstallationInfo\x12\x1a\n\rrack_location\x18\x01 \x01(\tB\x03\xe0\x41\x02\x12\"\n\x15power_distance_meters\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\x12#\n\x16switch_distance_meters\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02\x12Y\n\x14rack_unit_dimensions\x18\x04 \x01(\x0b\x32\x36.google.cloud.gdchardwaremanagement.v1alpha.DimensionsB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x05 \x01(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x02\x12\x65\n\track_type\x18\x06 \x01(\x0e\x32M.google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackTypeB\x03\xe0\x41\x02\"B\n\x08RackType\x12\x19\n\x15RACK_TYPE_UNSPECIFIED\x10\x00\x12\x0c\n\x08TWO_POST\x10\x01\x12\r\n\tFOUR_POST\x10\x02\"\xb0\x03\n\x11ZoneNetworkConfig\x12,\n\x17machine_mgmt_ipv4_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1akubernetes_node_ipv4_range\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\x38\n#kubernetes_control_plane_ipv4_range\x18\x03 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12W\n\x16management_ipv4_subnet\x18\x04 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x02\x12W\n\x16kubernetes_ipv4_subnet\x18\x05 \x01(\x0b\x32\x32.google.cloud.gdchardwaremanagement.v1alpha.SubnetB\x03\xe0\x41\x01\x12\'\n\x12\x64ns_ipv4_addresses\x18\x06 \x03(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12\'\n\x1akubernetes_primary_vlan_id\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\"]\n\x06Subnet\x12\"\n\raddress_range\x18\x01 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\x12/\n\x1a\x64\x65\x66\x61ult_gateway_ip_address\x18\x02 \x01(\tB\x0b\xe0\x41\x02\xe2\x8c\xcf\xd7\x08\x02\x08\x02\"\x97\x01\n\nTimePeriod\x12/\n\nstart_time\x18\x01 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12-\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x02\x12)\n\x04\x64\x61ys\x18\x03 \x03(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x02\"^\n\nDimensions\x12\x19\n\x0cwidth_inches\x18\x01 \x01(\x02\x42\x03\xe0\x41\x02\x12\x1a\n\rheight_inches\x18\x02 \x01(\x02\x42\x03\xe0\x41\x02\x12\x19\n\x0c\x64\x65pth_inches\x18\x03 \x01(\x02\x42\x03\xe0\x41\x02\"E\n\tRackSpace\x12\x1c\n\x0fstart_rack_unit\x18\x01 \x01(\x05\x42\x03\xe0\x41\x02\x12\x1a\n\rend_rack_unit\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02\"\xbf\x01\n\x10HardwareLocation\x12?\n\x04site\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1a\n\rrack_location\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12N\n\nrack_space\x18\x03 \x03(\x0b\x32\x35.google.cloud.gdchardwaremanagement.v1alpha.RackSpaceB\x03\xe0\x41\x01\"\xb7\x02\n\x12SubscriptionConfig\x12\x1c\n\x0fsubscription_id\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nbilling_id\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x64\n\x05state\x18\x03 \x01(\x0e\x32P.google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionStateB\x03\xe0\x41\x03\"\x83\x01\n\x11SubscriptionState\x12\"\n\x1eSUBSCRIPTION_STATE_UNSPECIFIED\x10\x00\x12\n\n\x06\x41\x43TIVE\x10\x01\x12\x0c\n\x08INACTIVE\x10\x02\x12\t\n\x05\x45RROR\x10\x03\x12\x16\n\x12\x46\x41ILED_TO_RETRIEVE\x10\x04\x12\r\n\tCOMPLETED\x10\x05*U\n\x0bPowerSupply\x12\x1c\n\x18POWER_SUPPLY_UNSPECIFIED\x10\x00\x12\x13\n\x0fPOWER_SUPPLY_AC\x10\x01\x12\x13\n\x0fPOWER_SUPPLY_DC\x10\x02*F\n\x06\x45ntity\x12\x16\n\x12\x45NTITY_UNSPECIFIED\x10\x00\x12\n\n\x06GOOGLE\x10\x01\x12\x0c\n\x08\x43USTOMER\x10\x02\x12\n\n\x06VENDOR\x10\x03\x42\xb2\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0eResourcesProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" - -pool = Google::Protobuf::DescriptorPool.generated_pool - -begin - pool.add_serialized_file(descriptor_data) -rescue TypeError - # Compatibility code: will be removed in the next major version. - require 'google/protobuf/descriptor_pb' - parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) - parsed.clear_dependency - serialized = parsed.class.encode(parsed) - file = pool.add_serialized_file(serialized) - warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" - imports = [ - ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], - ["google.type.Date", "google/type/date.proto"], - ["google.type.PostalAddress", "google/type/postal_address.proto"], - ["google.type.TimeZone", "google/type/datetime.proto"], - ["google.type.TimeOfDay", "google/type/timeofday.proto"], - ] - imports.each do |type_name, expected_filename| - import_file = pool.lookup(type_name).file_descriptor - if import_file.name != expected_filename - warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" - end - end - warn "Each proto file must use a consistent fully-qualified name." - warn "This will become an error in the next major version." -end - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - Order = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order").msgclass - Order::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.State").enummodule - Order::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.Type").enummodule - Order::DeploymentType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Order.DeploymentType").enummodule - Site = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Site").msgclass - HardwareGroup = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup").msgclass - HardwareGroup::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup.State").enummodule - Hardware = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware").msgclass - Hardware::MacAddress = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress").msgclass - Hardware::MacAddress::AddressType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MacAddress.AddressType").enummodule - Hardware::DiskInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.DiskInfo").msgclass - Hardware::MachineInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.MachineInfo").msgclass - Hardware::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Hardware.State").enummodule - Comment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Comment").msgclass - ChangeLogEntry = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry").msgclass - Sku = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku").msgclass - Sku::Range = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku.Range").msgclass - Sku::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Sku.Type").enummodule - Zone = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone").msgclass - Zone::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone.State").enummodule - Zone::ProvisioningState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Zone.ProvisioningState").enummodule - OrganizationContact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.OrganizationContact").msgclass - Contact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Contact").msgclass - HardwareConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareConfig").msgclass - SkuConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SkuConfig").msgclass - SkuInstance = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SkuInstance").msgclass - HardwarePhysicalInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo").msgclass - HardwarePhysicalInfo::PowerReceptacleType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.PowerReceptacleType").enummodule - HardwarePhysicalInfo::NetworkUplinkType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.NetworkUplinkType").enummodule - HardwarePhysicalInfo::Voltage = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.Voltage").enummodule - HardwarePhysicalInfo::Amperes = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwarePhysicalInfo.Amperes").enummodule - HardwareInstallationInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo").msgclass - HardwareInstallationInfo::RackType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareInstallationInfo.RackType").enummodule - ZoneNetworkConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ZoneNetworkConfig").msgclass - Subnet = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Subnet").msgclass - TimePeriod = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.TimePeriod").msgclass - Dimensions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Dimensions").msgclass - RackSpace = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RackSpace").msgclass - HardwareLocation = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.HardwareLocation").msgclass - SubscriptionConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig").msgclass - SubscriptionConfig::SubscriptionState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubscriptionConfig.SubscriptionState").enummodule - PowerSupply = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.PowerSupply").enummodule - Entity = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.Entity").enummodule - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb deleted file mode 100644 index 644c021c1880..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_pb.rb +++ /dev/null @@ -1,107 +0,0 @@ -# frozen_string_literal: true -# Generated by the protocol buffer compiler. DO NOT EDIT! -# source: google/cloud/gdchardwaremanagement/v1alpha/service.proto - -require 'google/protobuf' - -require 'google/api/annotations_pb' -require 'google/api/client_pb' -require 'google/api/field_behavior_pb' -require 'google/api/field_info_pb' -require 'google/api/resource_pb' -require 'google/cloud/gdchardwaremanagement/v1alpha/resources_pb' -require 'google/longrunning/operations_pb' -require 'google/protobuf/empty_pb' -require 'google/protobuf/field_mask_pb' -require 'google/protobuf/timestamp_pb' -require 'google/type/date_pb' - - -descriptor_data = "\n8google/cloud/gdchardwaremanagement/v1alpha/service.proto\x12*google.cloud.gdchardwaremanagement.v1alpha\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a:google/cloud/gdchardwaremanagement/v1alpha/resources.proto\x1a#google/longrunning/operations.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x16google/type/date.proto\"\xb4\x01\n\x11ListOrdersRequest\x12\x42\n\x06parent\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\x12*gdchardwaremanagement.googleapis.com/Order\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x85\x01\n\x12ListOrdersResponse\x12\x41\n\x06orders\x18\x01 \x03(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.Order\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"S\n\x0fGetOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\"\xcf\x01\n\x12\x43reateOrderRequest\x12\x42\n\x06parent\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\x12*gdchardwaremanagement.googleapis.com/Order\x12\x15\n\x08order_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x45\n\x05order\x18\x03 \x01(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.OrderB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xaa\x01\n\x12UpdateOrderRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x45\n\x05order\x18\x02 \x01(\x0b\x32\x31.google.cloud.gdchardwaremanagement.v1alpha.OrderB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x83\x01\n\x12\x44\x65leteOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x12\n\x05\x66orce\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\x8a\x02\n\x12SubmitOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12V\n\x04type\x18\x03 \x01(\x0e\x32\x43.google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest.TypeB\x03\xe0\x41\x01\"A\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x10\n\x0cINFO_PENDING\x10\x01\x12\x11\n\rINFO_COMPLETE\x10\x02\"w\n\x12\x43\x61ncelOrderRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xb2\x01\n\x10ListSitesRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Site\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x82\x01\n\x11ListSitesResponse\x12?\n\x05sites\x18\x01 \x03(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.Site\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Q\n\x0eGetSiteRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\"\xca\x01\n\x11\x43reateSiteRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Site\x12\x14\n\x07site_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x43\n\x04site\x18\x03 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.SiteB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xa7\x01\n\x11UpdateSiteRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x43\n\x04site\x18\x02 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.SiteB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"u\n\x11\x44\x65leteSiteRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Site\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xc4\x01\n\x19ListHardwareGroupsRequest\x12J\n\x06parent\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\x12\x32gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x9e\x01\n\x1aListHardwareGroupsResponse\x12R\n\x0fhardware_groups\x18\x01 \x03(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"c\n\x17GetHardwareGroupRequest\x12H\n\x04name\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\"\xf9\x01\n\x1a\x43reateHardwareGroupRequest\x12J\n\x06parent\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\x12\x32gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x1e\n\x11hardware_group_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12V\n\x0ehardware_group\x18\x03 \x01(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroupB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\xc3\x01\n\x1aUpdateHardwareGroupRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12V\n\x0ehardware_group\x18\x02 \x01(\x0b\x32\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroupB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x7f\n\x1a\x44\x65leteHardwareGroupRequest\x12H\n\x04name\x18\x01 \x01(\tB:\xe0\x41\x02\xfa\x41\x34\n2gdchardwaremanagement.googleapis.com/HardwareGroup\x12\x17\n\nrequest_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\"\xb9\x01\n\x13ListHardwareRequest\x12\x45\n\x06parent\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\x12-gdchardwaremanagement.googleapis.com/Hardware\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x8c\x01\n\x14ListHardwareResponse\x12\x46\n\x08hardware\x18\x01 \x03(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.Hardware\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Y\n\x12GetHardwareRequest\x12\x43\n\x04name\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\n-gdchardwaremanagement.googleapis.com/Hardware\"\xc5\x01\n\x15\x43reateHardwareRequest\x12\x45\n\x06parent\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\x12-gdchardwaremanagement.googleapis.com/Hardware\x12\x18\n\x0bhardware_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12K\n\x08hardware\x18\x03 \x01(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.HardwareB\x03\xe0\x41\x02\"\xb3\x01\n\x15UpdateHardwareRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12K\n\x08hardware\x18\x02 \x01(\x0b\x32\x34.google.cloud.gdchardwaremanagement.v1alpha.HardwareB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x03 \x01(\tB\x03\xe0\x41\x01\"}\n\x15\x44\x65leteHardwareRequest\x12\x43\n\x04name\x18\x01 \x01(\tB5\xe0\x41\x02\xfa\x41/\n-gdchardwaremanagement.googleapis.com/Hardware\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xb8\x01\n\x13ListCommentsRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,gdchardwaremanagement.googleapis.com/Comment\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x8b\x01\n\x14ListCommentsResponse\x12\x45\n\x08\x63omments\x18\x01 \x03(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"W\n\x11GetCommentRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,gdchardwaremanagement.googleapis.com/Comment\"\xd9\x01\n\x14\x43reateCommentRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,gdchardwaremanagement.googleapis.com/Comment\x12\x17\n\ncomment_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12I\n\x07\x63omment\x18\x03 \x01(\x0b\x32\x33.google.cloud.gdchardwaremanagement.v1alpha.CommentB\x03\xe0\x41\x02\x12\x17\n\nrequest_id\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x92\x02\n\x1cRecordActionOnCommentRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,gdchardwaremanagement.googleapis.com/Comment\x12m\n\x0b\x61\x63tion_type\x18\x02 \x01(\x0e\x32S.google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest.ActionTypeB\x03\xe0\x41\x02\"?\n\nActionType\x12\x1b\n\x17\x41\x43TION_TYPE_UNSPECIFIED\x10\x00\x12\x08\n\x04READ\x10\x01\x12\n\n\x06UNREAD\x10\x02\"\xc7\x01\n\x1bListChangeLogEntriesRequest\x12K\n\x06parent\x18\x01 \x01(\tB;\xe0\x41\x02\xfa\x41\x35\x12\x33gdchardwaremanagement.googleapis.com/ChangeLogEntry\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\xa4\x01\n\x1cListChangeLogEntriesResponse\x12V\n\x12\x63hange_log_entries\x18\x01 \x03(\x0b\x32:.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"e\n\x18GetChangeLogEntryRequest\x12I\n\x04name\x18\x01 \x01(\tB;\xe0\x41\x02\xfa\x41\x35\n3gdchardwaremanagement.googleapis.com/ChangeLogEntry\"\xb0\x01\n\x0fListSkusRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\x12(gdchardwaremanagement.googleapis.com/Sku\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x7f\n\x10ListSkusResponse\x12=\n\x04skus\x18\x01 \x03(\x0b\x32/.google.cloud.gdchardwaremanagement.v1alpha.Sku\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"O\n\rGetSkuRequest\x12>\n\x04name\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(gdchardwaremanagement.googleapis.com/Sku\"\xb2\x01\n\x10ListZonesRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Zone\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x82\x01\n\x11ListZonesResponse\x12?\n\x05zones\x18\x01 \x03(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.Zone\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\x12\x13\n\x0bunreachable\x18\x03 \x03(\t\"Q\n\x0eGetZoneRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\"\xd2\x01\n\x11\x43reateZoneRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)gdchardwaremanagement.googleapis.com/Zone\x12\x14\n\x07zone_id\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x43\n\x04zone\x18\x03 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.ZoneB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x04 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xaf\x01\n\x11UpdateZoneRequest\x12\x34\n\x0bupdate_mask\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02\x12\x43\n\x04zone\x18\x02 \x01(\x0b\x32\x30.google.cloud.gdchardwaremanagement.v1alpha.ZoneB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x03 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"u\n\x11\x44\x65leteZoneRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xee\x05\n\x16SignalZoneStateRequest\x12?\n\x04name\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\n)gdchardwaremanagement.googleapis.com/Zone\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\x12i\n\x0cstate_signal\x18\x03 \x01(\x0e\x32N.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.StateSignalB\x03\xe0\x41\x01\x12\x82\x01\n\x19provisioning_state_signal\x18\x04 \x01(\x0e\x32Z.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.ProvisioningStateSignalB\x03\xe0\x41\x01\x12\x11\n\x04step\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12\x14\n\x07\x64\x65tails\x18\x06 \x01(\tB\x03\xe0\x41\x01\"\xd9\x01\n\x0bStateSignal\x12\x1c\n\x18STATE_SIGNAL_UNSPECIFIED\x10\x00\x12!\n\x1d\x46\x41\x43TORY_TURNUP_CHECKS_STARTED\x10\x03\x12 \n\x1c\x46\x41\x43TORY_TURNUP_CHECKS_PASSED\x10\x01\x12\x1d\n\x15READY_FOR_SITE_TURNUP\x10\x01\x1a\x02\x08\x01\x12 \n\x1c\x46\x41\x43TORY_TURNUP_CHECKS_FAILED\x10\x02\x12\"\n\x1eVERIFY_CLUSTER_INTENT_PRESENCE\x10\x04\x1a\x02\x10\x01\"}\n\x17ProvisioningStateSignal\x12)\n%PROVISIONING_STATE_SIGNAL_UNSPECIFIED\x10\x00\x12\x1c\n\x18PROVISIONING_IN_PROGRESS\x10\x01\x12\x19\n\x15PROVISIONING_COMPLETE\x10\x02\"\x80\x02\n\x11OperationMetadata\x12\x34\n\x0b\x63reate_time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x31\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x13\n\x06target\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04verb\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x1b\n\x0estatus_message\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12#\n\x16requested_cancellation\x18\x06 \x01(\x08\x42\x03\xe0\x41\x03\x12\x18\n\x0b\x61pi_version\x18\x07 \x01(\tB\x03\xe0\x41\x03\"\x91\x01\n\x1dRequestOrderDateChangeRequest\x12@\n\x04name\x18\x01 \x01(\tB2\xe0\x41\x02\xfa\x41,\n*gdchardwaremanagement.googleapis.com/Order\x12.\n\x0erequested_date\x18\x02 \x01(\x0b\x32\x11.google.type.DateB\x03\xe0\x41\x02\x32\xaf\x42\n\x15GDCHardwareManagement\x12\xcd\x01\n\nListOrders\x12=.google.cloud.gdchardwaremanagement.v1alpha.ListOrdersRequest\x1a>.google.cloud.gdchardwaremanagement.v1alpha.ListOrdersResponse\"@\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x31\x12//v1alpha/{parent=projects/*/locations/*}/orders\x12\xba\x01\n\x08GetOrder\x12;.google.cloud.gdchardwaremanagement.v1alpha.GetOrderRequest\x1a\x31.google.cloud.gdchardwaremanagement.v1alpha.Order\">\xda\x41\x04name\x82\xd3\xe4\x93\x02\x31\x12//v1alpha/{name=projects/*/locations/*/orders/*}\x12\xe1\x01\n\x0b\x43reateOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.CreateOrderRequest\x1a\x1d.google.longrunning.Operation\"s\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x15parent,order,order_id\x82\xd3\xe4\x93\x02\x38\"//v1alpha/{parent=projects/*/locations/*}/orders:\x05order\x12\xe3\x01\n\x0bUpdateOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.UpdateOrderRequest\x1a\x1d.google.longrunning.Operation\"u\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x11order,update_mask\x82\xd3\xe4\x93\x02>25/v1alpha/{order.name=projects/*/locations/*/orders/*}:\x05order\x12\xd9\x01\n\x0b\x44\x65leteOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.DeleteOrderRequest\x1a\x1d.google.longrunning.Operation\"k\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x31*//v1alpha/{name=projects/*/locations/*/orders/*}\x12\xd3\x01\n\x0bSubmitOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest\x1a\x1d.google.longrunning.Operation\"e\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02;\"6/v1alpha/{name=projects/*/locations/*/orders/*}:submit:\x01*\x12\xd3\x01\n\x0b\x43\x61ncelOrder\x12>.google.cloud.gdchardwaremanagement.v1alpha.CancelOrderRequest\x1a\x1d.google.longrunning.Operation\"e\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02;\"6/v1alpha/{name=projects/*/locations/*/orders/*}:cancel:\x01*\x12\xc9\x01\n\tListSites\x12<.google.cloud.gdchardwaremanagement.v1alpha.ListSitesRequest\x1a=.google.cloud.gdchardwaremanagement.v1alpha.ListSitesResponse\"?\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{parent=projects/*/locations/*}/sites\x12\xb6\x01\n\x07GetSite\x12:.google.cloud.gdchardwaremanagement.v1alpha.GetSiteRequest\x1a\x30.google.cloud.gdchardwaremanagement.v1alpha.Site\"=\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{name=projects/*/locations/*/sites/*}\x12\xda\x01\n\nCreateSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.CreateSiteRequest\x1a\x1d.google.longrunning.Operation\"n\xca\x41\x19\n\x04Site\x12\x11OperationMetadata\xda\x41\x13parent,site,site_id\x82\xd3\xe4\x93\x02\x36\"./v1alpha/{parent=projects/*/locations/*}/sites:\x04site\x12\xdc\x01\n\nUpdateSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.UpdateSiteRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Site\x12\x11OperationMetadata\xda\x41\x10site,update_mask\x82\xd3\xe4\x93\x02;23/v1alpha/{site.name=projects/*/locations/*/sites/*}:\x04site\x12\xd6\x01\n\nDeleteSite\x12=.google.cloud.gdchardwaremanagement.v1alpha.DeleteSiteRequest\x1a\x1d.google.longrunning.Operation\"j\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30*./v1alpha/{name=projects/*/locations/*/sites/*}\x12\xf6\x01\n\x12ListHardwareGroups\x12\x45.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsRequest\x1a\x46.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsResponse\"Q\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x42\x12@/v1alpha/{parent=projects/*/locations/*/orders/*}/hardwareGroups\x12\xe3\x01\n\x10GetHardwareGroup\x12\x43.google.cloud.gdchardwaremanagement.v1alpha.GetHardwareGroupRequest\x1a\x39.google.cloud.gdchardwaremanagement.v1alpha.HardwareGroup\"O\xda\x41\x04name\x82\xd3\xe4\x93\x02\x42\x12@/v1alpha/{name=projects/*/locations/*/orders/*/hardwareGroups/*}\x12\xa6\x02\n\x13\x43reateHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"\xa7\x01\xca\x41\"\n\rHardwareGroup\x12\x11OperationMetadata\xda\x41\'parent,hardware_group,hardware_group_id\x82\xd3\xe4\x93\x02R\"@/v1alpha/{parent=projects/*/locations/*/orders/*}/hardwareGroups:\x0ehardware_group\x12\xa8\x02\n\x13UpdateHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"\xa9\x01\xca\x41\"\n\rHardwareGroup\x12\x11OperationMetadata\xda\x41\x1ahardware_group,update_mask\x82\xd3\xe4\x93\x02\x61\x32O/v1alpha/{hardware_group.name=projects/*/locations/*/orders/*/hardwareGroups/*}:\x0ehardware_group\x12\xfa\x01\n\x13\x44\x65leteHardwareGroup\x12\x46.google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareGroupRequest\x1a\x1d.google.longrunning.Operation\"|\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x42*@/v1alpha/{name=projects/*/locations/*/orders/*/hardwareGroups/*}\x12\xd5\x01\n\x0cListHardware\x12?.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareRequest\x1a@.google.cloud.gdchardwaremanagement.v1alpha.ListHardwareResponse\"B\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x33\x12\x31/v1alpha/{parent=projects/*/locations/*}/hardware\x12\xc5\x01\n\x0bGetHardware\x12>.google.cloud.gdchardwaremanagement.v1alpha.GetHardwareRequest\x1a\x34.google.cloud.gdchardwaremanagement.v1alpha.Hardware\"@\xda\x41\x04name\x82\xd3\xe4\x93\x02\x33\x12\x31/v1alpha/{name=projects/*/locations/*/hardware/*}\x12\xf6\x01\n\x0e\x43reateHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareRequest\x1a\x1d.google.longrunning.Operation\"\x81\x01\xca\x41\x1d\n\x08Hardware\x12\x11OperationMetadata\xda\x41\x1bparent,hardware,hardware_id\x82\xd3\xe4\x93\x02=\"1/v1alpha/{parent=projects/*/locations/*}/hardware:\x08hardware\x12\xf8\x01\n\x0eUpdateHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareRequest\x1a\x1d.google.longrunning.Operation\"\x83\x01\xca\x41\x1d\n\x08Hardware\x12\x11OperationMetadata\xda\x41\x14hardware,update_mask\x82\xd3\xe4\x93\x02\x46\x32:/v1alpha/{hardware.name=projects/*/locations/*/hardware/*}:\x08hardware\x12\xe1\x01\n\x0e\x44\x65leteHardware\x12\x41.google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareRequest\x1a\x1d.google.longrunning.Operation\"m\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x33*1/v1alpha/{name=projects/*/locations/*/hardware/*}\x12\xde\x01\n\x0cListComments\x12?.google.cloud.gdchardwaremanagement.v1alpha.ListCommentsRequest\x1a@.google.cloud.gdchardwaremanagement.v1alpha.ListCommentsResponse\"K\xda\x41\x06parent\x82\xd3\xe4\x93\x02<\x12:/v1alpha/{parent=projects/*/locations/*/orders/*}/comments\x12\xcb\x01\n\nGetComment\x12=.google.cloud.gdchardwaremanagement.v1alpha.GetCommentRequest\x1a\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\"I\xda\x41\x04name\x82\xd3\xe4\x93\x02<\x12:/v1alpha/{name=projects/*/locations/*/orders/*/comments/*}\x12\xf9\x01\n\rCreateComment\x12@.google.cloud.gdchardwaremanagement.v1alpha.CreateCommentRequest\x1a\x1d.google.longrunning.Operation\"\x86\x01\xca\x41\x1c\n\x07\x43omment\x12\x11OperationMetadata\xda\x41\x19parent,comment,comment_id\x82\xd3\xe4\x93\x02\x45\":/v1alpha/{parent=projects/*/locations/*/orders/*}/comments:\x07\x63omment\x12\xfd\x01\n\x15RecordActionOnComment\x12H.google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest\x1a\x33.google.cloud.gdchardwaremanagement.v1alpha.Comment\"e\xda\x41\x10name,action_type\x82\xd3\xe4\x93\x02L\"G/v1alpha/{name=projects/*/locations/*/orders/*/comments/*}:recordAction:\x01*\x12\xfe\x01\n\x14ListChangeLogEntries\x12G.google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesRequest\x1aH.google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesResponse\"S\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x44\x12\x42/v1alpha/{parent=projects/*/locations/*/orders/*}/changeLogEntries\x12\xe8\x01\n\x11GetChangeLogEntry\x12\x44.google.cloud.gdchardwaremanagement.v1alpha.GetChangeLogEntryRequest\x1a:.google.cloud.gdchardwaremanagement.v1alpha.ChangeLogEntry\"Q\xda\x41\x04name\x82\xd3\xe4\x93\x02\x44\x12\x42/v1alpha/{name=projects/*/locations/*/orders/*/changeLogEntries/*}\x12\xc5\x01\n\x08ListSkus\x12;.google.cloud.gdchardwaremanagement.v1alpha.ListSkusRequest\x1a<.google.cloud.gdchardwaremanagement.v1alpha.ListSkusResponse\">\xda\x41\x06parent\x82\xd3\xe4\x93\x02/\x12-/v1alpha/{parent=projects/*/locations/*}/skus\x12\xb2\x01\n\x06GetSku\x12\x39.google.cloud.gdchardwaremanagement.v1alpha.GetSkuRequest\x1a/.google.cloud.gdchardwaremanagement.v1alpha.Sku\"<\xda\x41\x04name\x82\xd3\xe4\x93\x02/\x12-/v1alpha/{name=projects/*/locations/*/skus/*}\x12\xc9\x01\n\tListZones\x12<.google.cloud.gdchardwaremanagement.v1alpha.ListZonesRequest\x1a=.google.cloud.gdchardwaremanagement.v1alpha.ListZonesResponse\"?\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{parent=projects/*/locations/*}/zones\x12\xb6\x01\n\x07GetZone\x12:.google.cloud.gdchardwaremanagement.v1alpha.GetZoneRequest\x1a\x30.google.cloud.gdchardwaremanagement.v1alpha.Zone\"=\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30\x12./v1alpha/{name=projects/*/locations/*/zones/*}\x12\xda\x01\n\nCreateZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.CreateZoneRequest\x1a\x1d.google.longrunning.Operation\"n\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x13parent,zone,zone_id\x82\xd3\xe4\x93\x02\x36\"./v1alpha/{parent=projects/*/locations/*}/zones:\x04zone\x12\xdc\x01\n\nUpdateZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.UpdateZoneRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x10zone,update_mask\x82\xd3\xe4\x93\x02;23/v1alpha/{zone.name=projects/*/locations/*/zones/*}:\x04zone\x12\xd6\x01\n\nDeleteZone\x12=.google.cloud.gdchardwaremanagement.v1alpha.DeleteZoneRequest\x1a\x1d.google.longrunning.Operation\"j\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x30*./v1alpha/{name=projects/*/locations/*/zones/*}\x12\xe6\x01\n\x0fSignalZoneState\x12\x42.google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest\x1a\x1d.google.longrunning.Operation\"p\xca\x41\x19\n\x04Zone\x12\x11OperationMetadata\xda\x41\x11name,state_signal\x82\xd3\xe4\x93\x02:\"5/v1alpha/{name=projects/*/locations/*/zones/*}:signal:\x01*\x12\x83\x02\n\x16RequestOrderDateChange\x12I.google.cloud.gdchardwaremanagement.v1alpha.RequestOrderDateChangeRequest\x1a\x1d.google.longrunning.Operation\"\x7f\xca\x41\x1a\n\x05Order\x12\x11OperationMetadata\xda\x41\x13name,requested_date\x82\xd3\xe4\x93\x02\x46\"A/v1alpha/{name=projects/*/locations/*/orders/*}:requestDateChange:\x01*\x1aX\xca\x41$gdchardwaremanagement.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\xb0\x02\n.com.google.cloud.gdchardwaremanagement.v1alphaB\x0cServiceProtoP\x01Zdcloud.google.com/go/gdchardwaremanagement/apiv1alpha/gdchardwaremanagementpb;gdchardwaremanagementpb\xaa\x02*Google.Cloud.GdcHardwareManagement.V1Alpha\xca\x02*Google\\Cloud\\GdcHardwareManagement\\V1alpha\xea\x02-Google::Cloud::GDCHardwareManagement::V1alphab\x06proto3" - -pool = Google::Protobuf::DescriptorPool.generated_pool - -begin - pool.add_serialized_file(descriptor_data) -rescue TypeError - # Compatibility code: will be removed in the next major version. - require 'google/protobuf/descriptor_pb' - parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) - parsed.clear_dependency - serialized = parsed.class.encode(parsed) - file = pool.add_serialized_file(serialized) - warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" - imports = [ - ["google.cloud.gdchardwaremanagement.v1alpha.Order", "google/cloud/gdchardwaremanagement/v1alpha/resources.proto"], - ["google.protobuf.FieldMask", "google/protobuf/field_mask.proto"], - ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], - ["google.type.Date", "google/type/date.proto"], - ] - imports.each do |type_name, expected_filename| - import_file = pool.lookup(type_name).file_descriptor - if import_file.name != expected_filename - warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" - end - end - warn "Each proto file must use a consistent fully-qualified name." - warn "This will become an error in the next major version." -end - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - ListOrdersRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListOrdersRequest").msgclass - ListOrdersResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListOrdersResponse").msgclass - GetOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetOrderRequest").msgclass - CreateOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateOrderRequest").msgclass - UpdateOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateOrderRequest").msgclass - DeleteOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteOrderRequest").msgclass - SubmitOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest").msgclass - SubmitOrderRequest::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SubmitOrderRequest.Type").enummodule - CancelOrderRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CancelOrderRequest").msgclass - ListSitesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSitesRequest").msgclass - ListSitesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSitesResponse").msgclass - GetSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetSiteRequest").msgclass - CreateSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateSiteRequest").msgclass - UpdateSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateSiteRequest").msgclass - DeleteSiteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteSiteRequest").msgclass - ListHardwareGroupsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsRequest").msgclass - ListHardwareGroupsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareGroupsResponse").msgclass - GetHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetHardwareGroupRequest").msgclass - CreateHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareGroupRequest").msgclass - UpdateHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareGroupRequest").msgclass - DeleteHardwareGroupRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareGroupRequest").msgclass - ListHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareRequest").msgclass - ListHardwareResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListHardwareResponse").msgclass - GetHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetHardwareRequest").msgclass - CreateHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateHardwareRequest").msgclass - UpdateHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateHardwareRequest").msgclass - DeleteHardwareRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteHardwareRequest").msgclass - ListCommentsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListCommentsRequest").msgclass - ListCommentsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListCommentsResponse").msgclass - GetCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetCommentRequest").msgclass - CreateCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateCommentRequest").msgclass - RecordActionOnCommentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest").msgclass - RecordActionOnCommentRequest::ActionType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RecordActionOnCommentRequest.ActionType").enummodule - ListChangeLogEntriesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesRequest").msgclass - ListChangeLogEntriesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListChangeLogEntriesResponse").msgclass - GetChangeLogEntryRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetChangeLogEntryRequest").msgclass - ListSkusRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSkusRequest").msgclass - ListSkusResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListSkusResponse").msgclass - GetSkuRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetSkuRequest").msgclass - ListZonesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListZonesRequest").msgclass - ListZonesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.ListZonesResponse").msgclass - GetZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.GetZoneRequest").msgclass - CreateZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.CreateZoneRequest").msgclass - UpdateZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.UpdateZoneRequest").msgclass - DeleteZoneRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.DeleteZoneRequest").msgclass - SignalZoneStateRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest").msgclass - SignalZoneStateRequest::StateSignal = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.StateSignal").enummodule - SignalZoneStateRequest::ProvisioningStateSignal = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.SignalZoneStateRequest.ProvisioningStateSignal").enummodule - OperationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.OperationMetadata").msgclass - RequestOrderDateChangeRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.gdchardwaremanagement.v1alpha.RequestOrderDateChangeRequest").msgclass - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb deleted file mode 100644 index b7d920dba588..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/lib/google/cloud/gdchardwaremanagement/v1alpha/service_services_pb.rb +++ /dev/null @@ -1,120 +0,0 @@ -# Generated by the protocol buffer compiler. DO NOT EDIT! -# Source: google/cloud/gdchardwaremanagement/v1alpha/service.proto for package 'Google.Cloud.GDCHardwareManagement.V1alpha' -# Original file comments: -# Copyright 2025 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -require 'grpc' -require 'google/cloud/gdchardwaremanagement/v1alpha/service_pb' - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - module GDCHardwareManagement - # The GDC Hardware Management service. - class Service - - include ::GRPC::GenericService - - self.marshal_class_method = :encode - self.unmarshal_class_method = :decode - self.service_name = 'google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement' - - # Lists orders in a given project and location. - rpc :ListOrders, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse - # Gets details of an order. - rpc :GetOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Order - # Creates a new order in a given project and location. - rpc :CreateOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, ::Google::Longrunning::Operation - # Updates the parameters of an order. - rpc :UpdateOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, ::Google::Longrunning::Operation - # Deletes an order. - rpc :DeleteOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, ::Google::Longrunning::Operation - # Submits an order. - rpc :SubmitOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, ::Google::Longrunning::Operation - # Cancels an order. - rpc :CancelOrder, ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, ::Google::Longrunning::Operation - # Lists sites in a given project and location. - rpc :ListSites, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse - # Gets details of a site. - rpc :GetSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Site - # Creates a new site in a given project and location. - rpc :CreateSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, ::Google::Longrunning::Operation - # Updates the parameters of a site. - rpc :UpdateSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, ::Google::Longrunning::Operation - # Deletes a site. - rpc :DeleteSite, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, ::Google::Longrunning::Operation - # Lists hardware groups in a given order. - rpc :ListHardwareGroups, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse - # Gets details of a hardware group. - rpc :GetHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup - # Creates a new hardware group in a given order. - rpc :CreateHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, ::Google::Longrunning::Operation - # Updates the parameters of a hardware group. - rpc :UpdateHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, ::Google::Longrunning::Operation - # Deletes a hardware group. - rpc :DeleteHardwareGroup, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, ::Google::Longrunning::Operation - # Lists hardware in a given project and location. - rpc :ListHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse - # Gets hardware details. - rpc :GetHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware - # Creates new hardware in a given project and location. - rpc :CreateHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, ::Google::Longrunning::Operation - # Updates hardware parameters. - rpc :UpdateHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, ::Google::Longrunning::Operation - # Deletes hardware. - rpc :DeleteHardware, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, ::Google::Longrunning::Operation - # Lists the comments on an order. - rpc :ListComments, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse - # Gets the content of a comment. - rpc :GetComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment - # Creates a new comment on an order. - rpc :CreateComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, ::Google::Longrunning::Operation - # Record Action on a Comment. If the Action specified in the request is READ, - # the viewed time in the comment is set to the time the request was received. - # If the comment is already marked as read, subsequent calls will be ignored. - # If the Action is UNREAD, the viewed time is cleared from the comment. - rpc :RecordActionOnComment, ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment - # Lists the changes made to an order. - rpc :ListChangeLogEntries, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse - # Gets details of a change to an order. - rpc :GetChangeLogEntry, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry - # Lists SKUs for a given project and location. - rpc :ListSkus, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse - # Gets details of an SKU. - rpc :GetSku, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku - # Lists zones in a given project and location. - rpc :ListZones, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse - # Gets details of a zone. - rpc :GetZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone - # Creates a new zone in a given project and location. - rpc :CreateZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, ::Google::Longrunning::Operation - # Updates the parameters of a zone. - rpc :UpdateZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, ::Google::Longrunning::Operation - # Deletes a zone. - rpc :DeleteZone, ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, ::Google::Longrunning::Operation - # Signals the state of a zone. - rpc :SignalZoneState, ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, ::Google::Longrunning::Operation - # Updates the requested date change of a single Order. - rpc :RequestOrderDateChange, ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, ::Google::Longrunning::Operation - end - - Stub = Service.rpc_stub_class - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md deleted file mode 100644 index 7e80aeaac20b..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/README.md +++ /dev/null @@ -1,4 +0,0 @@ -# GDC Hardware Management V1ALPHA Protocol Buffer Documentation - -These files are for the YARD documentation of the generated protobuf files. -They are not intended to be required or loaded at runtime. diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb deleted file mode 100644 index d59ba51a5612..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/client.rb +++ /dev/null @@ -1,473 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Api - # Required information for every language. - # @!attribute [rw] reference_docs_uri - # @deprecated This field is deprecated and may be removed in the next major version update. - # @return [::String] - # Link to automatically generated reference documentation. Example: - # https://cloud.google.com/nodejs/docs/reference/asset/latest - # @!attribute [rw] destinations - # @return [::Array<::Google::Api::ClientLibraryDestination>] - # The destination where API teams want this client library to be published. - # @!attribute [rw] selective_gapic_generation - # @return [::Google::Api::SelectiveGapicGeneration] - # Configuration for which RPCs should be generated in the GAPIC client. - class CommonLanguageSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Details about how and where to publish client libraries. - # @!attribute [rw] version - # @return [::String] - # Version of the API to apply these settings to. This is the full protobuf - # package for the API, ending in the version element. - # Examples: "google.cloud.speech.v1" and "google.spanner.admin.database.v1". - # @!attribute [rw] launch_stage - # @return [::Google::Api::LaunchStage] - # Launch stage of this version of the API. - # @!attribute [rw] rest_numeric_enums - # @return [::Boolean] - # When using transport=rest, the client request will encode enums as - # numbers rather than strings. - # @!attribute [rw] java_settings - # @return [::Google::Api::JavaSettings] - # Settings for legacy Java features, supported in the Service YAML. - # @!attribute [rw] cpp_settings - # @return [::Google::Api::CppSettings] - # Settings for C++ client libraries. - # @!attribute [rw] php_settings - # @return [::Google::Api::PhpSettings] - # Settings for PHP client libraries. - # @!attribute [rw] python_settings - # @return [::Google::Api::PythonSettings] - # Settings for Python client libraries. - # @!attribute [rw] node_settings - # @return [::Google::Api::NodeSettings] - # Settings for Node client libraries. - # @!attribute [rw] dotnet_settings - # @return [::Google::Api::DotnetSettings] - # Settings for .NET client libraries. - # @!attribute [rw] ruby_settings - # @return [::Google::Api::RubySettings] - # Settings for Ruby client libraries. - # @!attribute [rw] go_settings - # @return [::Google::Api::GoSettings] - # Settings for Go client libraries. - class ClientLibrarySettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # This message configures the settings for publishing [Google Cloud Client - # libraries](https://cloud.google.com/apis/docs/cloud-client-libraries) - # generated from the service config. - # @!attribute [rw] method_settings - # @return [::Array<::Google::Api::MethodSettings>] - # A list of API method settings, e.g. the behavior for methods that use the - # long-running operation pattern. - # @!attribute [rw] new_issue_uri - # @return [::String] - # Link to a *public* URI where users can report issues. Example: - # https://issuetracker.google.com/issues/new?component=190865&template=1161103 - # @!attribute [rw] documentation_uri - # @return [::String] - # Link to product home page. Example: - # https://cloud.google.com/asset-inventory/docs/overview - # @!attribute [rw] api_short_name - # @return [::String] - # Used as a tracking tag when collecting data about the APIs developer - # relations artifacts like docs, packages delivered to package managers, - # etc. Example: "speech". - # @!attribute [rw] github_label - # @return [::String] - # GitHub label to apply to issues and pull requests opened for this API. - # @!attribute [rw] codeowner_github_teams - # @return [::Array<::String>] - # GitHub teams to be added to CODEOWNERS in the directory in GitHub - # containing source code for the client libraries for this API. - # @!attribute [rw] doc_tag_prefix - # @return [::String] - # A prefix used in sample code when demarking regions to be included in - # documentation. - # @!attribute [rw] organization - # @return [::Google::Api::ClientLibraryOrganization] - # For whom the client library is being published. - # @!attribute [rw] library_settings - # @return [::Array<::Google::Api::ClientLibrarySettings>] - # Client library settings. If the same version string appears multiple - # times in this list, then the last one wins. Settings from earlier - # settings with the same version string are discarded. - # @!attribute [rw] proto_reference_documentation_uri - # @return [::String] - # Optional link to proto reference documentation. Example: - # https://cloud.google.com/pubsub/lite/docs/reference/rpc - # @!attribute [rw] rest_reference_documentation_uri - # @return [::String] - # Optional link to REST reference documentation. Example: - # https://cloud.google.com/pubsub/lite/docs/reference/rest - class Publishing - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Settings for Java client libraries. - # @!attribute [rw] library_package - # @return [::String] - # The package name to use in Java. Clobbers the java_package option - # set in the protobuf. This should be used **only** by APIs - # who have already set the language_settings.java.package_name" field - # in gapic.yaml. API teams should use the protobuf java_package option - # where possible. - # - # Example of a YAML configuration:: - # - # publishing: - # java_settings: - # library_package: com.google.cloud.pubsub.v1 - # @!attribute [rw] service_class_names - # @return [::Google::Protobuf::Map{::String => ::String}] - # Configure the Java class name to use instead of the service's for its - # corresponding generated GAPIC client. Keys are fully-qualified - # service names as they appear in the protobuf (including the full - # the language_settings.java.interface_names" field in gapic.yaml. API - # teams should otherwise use the service name as it appears in the - # protobuf. - # - # Example of a YAML configuration:: - # - # publishing: - # java_settings: - # service_class_names: - # - google.pubsub.v1.Publisher: TopicAdmin - # - google.pubsub.v1.Subscriber: SubscriptionAdmin - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - class JavaSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class ServiceClassNamesEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # Settings for C++ client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - class CppSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Settings for Php client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - class PhpSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Settings for Python client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - # @!attribute [rw] experimental_features - # @return [::Google::Api::PythonSettings::ExperimentalFeatures] - # Experimental features to be included during client library generation. - class PythonSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Experimental features to be included during client library generation. - # These fields will be deprecated once the feature graduates and is enabled - # by default. - # @!attribute [rw] rest_async_io_enabled - # @return [::Boolean] - # Enables generation of asynchronous REST clients if `rest` transport is - # enabled. By default, asynchronous REST clients will not be generated. - # This feature will be enabled by default 1 month after launching the - # feature in preview packages. - # @!attribute [rw] protobuf_pythonic_types_enabled - # @return [::Boolean] - # Enables generation of protobuf code using new types that are more - # Pythonic which are included in `protobuf>=5.29.x`. This feature will be - # enabled by default 1 month after launching the feature in preview - # packages. - # @!attribute [rw] unversioned_package_disabled - # @return [::Boolean] - # Disables generation of an unversioned Python package for this client - # library. This means that the module names will need to be versioned in - # import statements. For example `import google.cloud.library_v2` instead - # of `import google.cloud.library`. - class ExperimentalFeatures - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # Settings for Node client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - class NodeSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Settings for Dotnet client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - # @!attribute [rw] renamed_services - # @return [::Google::Protobuf::Map{::String => ::String}] - # Map from original service names to renamed versions. - # This is used when the default generated types - # would cause a naming conflict. (Neither name is - # fully-qualified.) - # Example: Subscriber to SubscriberServiceApi. - # @!attribute [rw] renamed_resources - # @return [::Google::Protobuf::Map{::String => ::String}] - # Map from full resource types to the effective short name - # for the resource. This is used when otherwise resource - # named from different services would cause naming collisions. - # Example entry: - # "datalabeling.googleapis.com/Dataset": "DataLabelingDataset" - # @!attribute [rw] ignored_resources - # @return [::Array<::String>] - # List of full resource types to ignore during generation. - # This is typically used for API-specific Location resources, - # which should be handled by the generator as if they were actually - # the common Location resources. - # Example entry: "documentai.googleapis.com/Location" - # @!attribute [rw] forced_namespace_aliases - # @return [::Array<::String>] - # Namespaces which must be aliased in snippets due to - # a known (but non-generator-predictable) naming collision - # @!attribute [rw] handwritten_signatures - # @return [::Array<::String>] - # Method signatures (in the form "service.method(signature)") - # which are provided separately, so shouldn't be generated. - # Snippets *calling* these methods are still generated, however. - class DotnetSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class RenamedServicesEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class RenamedResourcesEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # Settings for Ruby client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - class RubySettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Settings for Go client libraries. - # @!attribute [rw] common - # @return [::Google::Api::CommonLanguageSettings] - # Some settings. - # @!attribute [rw] renamed_services - # @return [::Google::Protobuf::Map{::String => ::String}] - # Map of service names to renamed services. Keys are the package relative - # service names and values are the name to be used for the service client - # and call options. - # - # publishing: - # go_settings: - # renamed_services: - # Publisher: TopicAdmin - class GoSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class RenamedServicesEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # Describes the generator configuration for a method. - # @!attribute [rw] selector - # @return [::String] - # The fully qualified name of the method, for which the options below apply. - # This is used to find the method to apply the options. - # - # Example: - # - # publishing: - # method_settings: - # - selector: google.storage.control.v2.StorageControl.CreateFolder - # # method settings for CreateFolder... - # @!attribute [rw] long_running - # @return [::Google::Api::MethodSettings::LongRunning] - # Describes settings to use for long-running operations when generating - # API methods for RPCs. Complements RPCs that use the annotations in - # google/longrunning/operations.proto. - # - # Example of a YAML configuration:: - # - # publishing: - # method_settings: - # - selector: google.cloud.speech.v2.Speech.BatchRecognize - # long_running: - # initial_poll_delay: 60s # 1 minute - # poll_delay_multiplier: 1.5 - # max_poll_delay: 360s # 6 minutes - # total_poll_timeout: 54000s # 90 minutes - # @!attribute [rw] auto_populated_fields - # @return [::Array<::String>] - # List of top-level fields of the request message, that should be - # automatically populated by the client libraries based on their - # (google.api.field_info).format. Currently supported format: UUID4. - # - # Example of a YAML configuration: - # - # publishing: - # method_settings: - # - selector: google.example.v1.ExampleService.CreateExample - # auto_populated_fields: - # - request_id - class MethodSettings - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Describes settings to use when generating API methods that use the - # long-running operation pattern. - # All default values below are from those used in the client library - # generators (e.g. - # [Java](https://github.com/googleapis/gapic-generator-java/blob/04c2faa191a9b5a10b92392fe8482279c4404803/src/main/java/com/google/api/generator/gapic/composer/common/RetrySettingsComposer.java)). - # @!attribute [rw] initial_poll_delay - # @return [::Google::Protobuf::Duration] - # Initial delay after which the first poll request will be made. - # Default value: 5 seconds. - # @!attribute [rw] poll_delay_multiplier - # @return [::Float] - # Multiplier to gradually increase delay between subsequent polls until it - # reaches max_poll_delay. - # Default value: 1.5. - # @!attribute [rw] max_poll_delay - # @return [::Google::Protobuf::Duration] - # Maximum time between two subsequent poll requests. - # Default value: 45 seconds. - # @!attribute [rw] total_poll_timeout - # @return [::Google::Protobuf::Duration] - # Total polling timeout. - # Default value: 5 minutes. - class LongRunning - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # This message is used to configure the generation of a subset of the RPCs in - # a service for client libraries. - # @!attribute [rw] methods - # @return [::Array<::String>] - # An allowlist of the fully qualified names of RPCs that should be included - # on public client surfaces. - # @!attribute [rw] generate_omitted_as_internal - # @return [::Boolean] - # Setting this to true indicates to the client generators that methods - # that would be excluded from the generation should instead be generated - # in a way that indicates these methods should not be consumed by - # end users. How this is expressed is up to individual language - # implementations to decide. Some examples may be: added annotations, - # obfuscated identifiers, or other language idiomatic patterns. - class SelectiveGapicGeneration - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The organization for which the client libraries are being published. - # Affects the url where generated docs are published, etc. - module ClientLibraryOrganization - # Not useful. - CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED = 0 - - # Google Cloud Platform Org. - CLOUD = 1 - - # Ads (Advertising) Org. - ADS = 2 - - # Photos Org. - PHOTOS = 3 - - # Street View Org. - STREET_VIEW = 4 - - # Shopping Org. - SHOPPING = 5 - - # Geo Org. - GEO = 6 - - # Generative AI - https://developers.generativeai.google - GENERATIVE_AI = 7 - end - - # To where should client libraries be published? - module ClientLibraryDestination - # Client libraries will neither be generated nor published to package - # managers. - CLIENT_LIBRARY_DESTINATION_UNSPECIFIED = 0 - - # Generate the client library in a repo under github.com/googleapis, - # but don't publish it to package managers. - GITHUB = 10 - - # Publish the library to package managers like nuget.org and npmjs.com. - PACKAGE_MANAGER = 20 - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb deleted file mode 100644 index 582be187d115..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_behavior.rb +++ /dev/null @@ -1,85 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Api - # An indicator of the behavior of a given field (for example, that a field - # is required in requests, or given as output but ignored as input). - # This **does not** change the behavior in protocol buffers itself; it only - # denotes the behavior and may affect how API tooling handles the field. - # - # Note: This enum **may** receive new values in the future. - module FieldBehavior - # Conventional default for enums. Do not use this. - FIELD_BEHAVIOR_UNSPECIFIED = 0 - - # Specifically denotes a field as optional. - # While all fields in protocol buffers are optional, this may be specified - # for emphasis if appropriate. - OPTIONAL = 1 - - # Denotes a field as required. - # This indicates that the field **must** be provided as part of the request, - # and failure to do so will cause an error (usually `INVALID_ARGUMENT`). - REQUIRED = 2 - - # Denotes a field as output only. - # This indicates that the field is provided in responses, but including the - # field in a request does nothing (the server *must* ignore it and - # *must not* throw an error as a result of the field's presence). - OUTPUT_ONLY = 3 - - # Denotes a field as input only. - # This indicates that the field is provided in requests, and the - # corresponding field is not included in output. - INPUT_ONLY = 4 - - # Denotes a field as immutable. - # This indicates that the field may be set once in a request to create a - # resource, but may not be changed thereafter. - IMMUTABLE = 5 - - # Denotes that a (repeated) field is an unordered list. - # This indicates that the service may provide the elements of the list - # in any arbitrary order, rather than the order the user originally - # provided. Additionally, the list's order may or may not be stable. - UNORDERED_LIST = 6 - - # Denotes that this field returns a non-empty default value if not set. - # This indicates that if the user provides the empty value in a request, - # a non-empty value will be returned. The user will not be aware of what - # non-empty value to expect. - NON_EMPTY_DEFAULT = 7 - - # Denotes that the field in a resource (a message annotated with - # google.api.resource) is used in the resource name to uniquely identify the - # resource. For AIP-compliant APIs, this should only be applied to the - # `name` field on the resource. - # - # This behavior should not be applied to references to other resources within - # the message. - # - # The identifier field of resources often have different field behavior - # depending on the request it is embedded in (e.g. for Create methods name - # is optional and unused, while for Update methods it is required). Instead - # of method-specific annotations, only `IDENTIFIER` is required. - IDENTIFIER = 8 - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb deleted file mode 100644 index 0f5acf0a5538..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/field_info.rb +++ /dev/null @@ -1,88 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Api - # Rich semantic information of an API field beyond basic typing. - # @!attribute [rw] format - # @return [::Google::Api::FieldInfo::Format] - # The standard format of a field value. This does not explicitly configure - # any API consumer, just documents the API's format for the field it is - # applied to. - # @!attribute [rw] referenced_types - # @return [::Array<::Google::Api::TypeReference>] - # The type(s) that the annotated, generic field may represent. - # - # Currently, this must only be used on fields of type `google.protobuf.Any`. - # Supporting other generic types may be considered in the future. - class FieldInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # The standard format of a field value. The supported formats are all backed - # by either an RFC defined by the IETF or a Google-defined AIP. - module Format - # Default, unspecified value. - FORMAT_UNSPECIFIED = 0 - - # Universally Unique Identifier, version 4, value as defined by - # https://datatracker.ietf.org/doc/html/rfc4122. The value may be - # normalized to entirely lowercase letters. For example, the value - # `F47AC10B-58CC-0372-8567-0E02B2C3D479` would be normalized to - # `f47ac10b-58cc-0372-8567-0e02b2c3d479`. - UUID4 = 1 - - # Internet Protocol v4 value as defined by [RFC - # 791](https://datatracker.ietf.org/doc/html/rfc791). The value may be - # condensed, with leading zeros in each octet stripped. For example, - # `001.022.233.040` would be condensed to `1.22.233.40`. - IPV4 = 2 - - # Internet Protocol v6 value as defined by [RFC - # 2460](https://datatracker.ietf.org/doc/html/rfc2460). The value may be - # normalized to entirely lowercase letters with zeros compressed, following - # [RFC 5952](https://datatracker.ietf.org/doc/html/rfc5952). For example, - # the value `2001:0DB8:0::0` would be normalized to `2001:db8::`. - IPV6 = 3 - - # An IP address in either v4 or v6 format as described by the individual - # values defined herein. See the comments on the IPV4 and IPV6 types for - # allowed normalizations of each. - IPV4_OR_IPV6 = 4 - end - end - - # A reference to a message type, for use in {::Google::Api::FieldInfo FieldInfo}. - # @!attribute [rw] type_name - # @return [::String] - # The name of the type that the annotated, generic field may represent. - # If the type is in the same protobuf package, the value can be the simple - # message name e.g., `"MyMessage"`. Otherwise, the value must be the - # fully-qualified message name e.g., `"google.library.v1.Book"`. - # - # If the type(s) are unknown to the service (e.g. the field accepts generic - # user input), use the wildcard `"*"` to denote this behavior. - # - # See [AIP-202](https://google.aip.dev/202#type-references) for more details. - class TypeReference - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb deleted file mode 100644 index 9392a413fb1b..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/launch_stage.rb +++ /dev/null @@ -1,71 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Api - # The launch stage as defined by [Google Cloud Platform - # Launch Stages](https://cloud.google.com/terms/launch-stages). - module LaunchStage - # Do not use this default value. - LAUNCH_STAGE_UNSPECIFIED = 0 - - # The feature is not yet implemented. Users can not use it. - UNIMPLEMENTED = 6 - - # Prelaunch features are hidden from users and are only visible internally. - PRELAUNCH = 7 - - # Early Access features are limited to a closed group of testers. To use - # these features, you must sign up in advance and sign a Trusted Tester - # agreement (which includes confidentiality provisions). These features may - # be unstable, changed in backward-incompatible ways, and are not - # guaranteed to be released. - EARLY_ACCESS = 1 - - # Alpha is a limited availability test for releases before they are cleared - # for widespread use. By Alpha, all significant design issues are resolved - # and we are in the process of verifying functionality. Alpha customers - # need to apply for access, agree to applicable terms, and have their - # projects allowlisted. Alpha releases don't have to be feature complete, - # no SLAs are provided, and there are no technical support obligations, but - # they will be far enough along that customers can actually use them in - # test environments or for limited-use tests -- just like they would in - # normal production cases. - ALPHA = 2 - - # Beta is the point at which we are ready to open a release for any - # customer to use. There are no SLA or technical support obligations in a - # Beta release. Products will be complete from a feature perspective, but - # may have some open outstanding issues. Beta releases are suitable for - # limited production use cases. - BETA = 3 - - # GA features are open to all developers and are considered stable and - # fully qualified for production use. - GA = 4 - - # Deprecated features are scheduled to be shut down and removed. For more - # information, see the "Deprecation Policy" section of our [Terms of - # Service](https://cloud.google.com/terms/) - # and the [Google Cloud Platform Subject to the Deprecation - # Policy](https://cloud.google.com/terms/deprecation) documentation. - DEPRECATED = 5 - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb deleted file mode 100644 index 25dec4847ac1..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/api/resource.rb +++ /dev/null @@ -1,227 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Api - # A simple descriptor of a resource type. - # - # ResourceDescriptor annotates a resource message (either by means of a - # protobuf annotation or use in the service config), and associates the - # resource's schema, the resource type, and the pattern of the resource name. - # - # Example: - # - # message Topic { - # // Indicates this message defines a resource schema. - # // Declares the resource type in the format of {service}/{kind}. - # // For Kubernetes resources, the format is {api group}/{kind}. - # option (google.api.resource) = { - # type: "pubsub.googleapis.com/Topic" - # pattern: "projects/{project}/topics/{topic}" - # }; - # } - # - # The ResourceDescriptor Yaml config will look like: - # - # resources: - # - type: "pubsub.googleapis.com/Topic" - # pattern: "projects/{project}/topics/{topic}" - # - # Sometimes, resources have multiple patterns, typically because they can - # live under multiple parents. - # - # Example: - # - # message LogEntry { - # option (google.api.resource) = { - # type: "logging.googleapis.com/LogEntry" - # pattern: "projects/{project}/logs/{log}" - # pattern: "folders/{folder}/logs/{log}" - # pattern: "organizations/{organization}/logs/{log}" - # pattern: "billingAccounts/{billing_account}/logs/{log}" - # }; - # } - # - # The ResourceDescriptor Yaml config will look like: - # - # resources: - # - type: 'logging.googleapis.com/LogEntry' - # pattern: "projects/{project}/logs/{log}" - # pattern: "folders/{folder}/logs/{log}" - # pattern: "organizations/{organization}/logs/{log}" - # pattern: "billingAccounts/{billing_account}/logs/{log}" - # @!attribute [rw] type - # @return [::String] - # The resource type. It must be in the format of - # \\{service_name}/\\{resource_type_kind}. The `resource_type_kind` must be - # singular and must not include version numbers. - # - # Example: `storage.googleapis.com/Bucket` - # - # The value of the resource_type_kind must follow the regular expression - # /[A-Za-z][a-zA-Z0-9]+/. It should start with an upper case character and - # should use PascalCase (UpperCamelCase). The maximum number of - # characters allowed for the `resource_type_kind` is 100. - # @!attribute [rw] pattern - # @return [::Array<::String>] - # Optional. The relative resource name pattern associated with this resource - # type. The DNS prefix of the full resource name shouldn't be specified here. - # - # The path pattern must follow the syntax, which aligns with HTTP binding - # syntax: - # - # Template = Segment { "/" Segment } ; - # Segment = LITERAL | Variable ; - # Variable = "{" LITERAL "}" ; - # - # Examples: - # - # - "projects/\\{project}/topics/\\{topic}" - # - "projects/\\{project}/knowledgeBases/\\{knowledge_base}" - # - # The components in braces correspond to the IDs for each resource in the - # hierarchy. It is expected that, if multiple patterns are provided, - # the same component name (e.g. "project") refers to IDs of the same - # type of resource. - # @!attribute [rw] name_field - # @return [::String] - # Optional. The field on the resource that designates the resource name - # field. If omitted, this is assumed to be "name". - # @!attribute [rw] history - # @return [::Google::Api::ResourceDescriptor::History] - # Optional. The historical or future-looking state of the resource pattern. - # - # Example: - # - # // The InspectTemplate message originally only supported resource - # // names with organization, and project was added later. - # message InspectTemplate { - # option (google.api.resource) = { - # type: "dlp.googleapis.com/InspectTemplate" - # pattern: - # "organizations/{organization}/inspectTemplates/{inspect_template}" - # pattern: "projects/{project}/inspectTemplates/{inspect_template}" - # history: ORIGINALLY_SINGLE_PATTERN - # }; - # } - # @!attribute [rw] plural - # @return [::String] - # The plural name used in the resource name and permission names, such as - # 'projects' for the resource name of 'projects/\\{project}' and the permission - # name of 'cloudresourcemanager.googleapis.com/projects.get'. One exception - # to this is for Nested Collections that have stuttering names, as defined - # in [AIP-122](https://google.aip.dev/122#nested-collections), where the - # collection ID in the resource name pattern does not necessarily directly - # match the `plural` value. - # - # It is the same concept of the `plural` field in k8s CRD spec - # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ - # - # Note: The plural form is required even for singleton resources. See - # https://aip.dev/156 - # @!attribute [rw] singular - # @return [::String] - # The same concept of the `singular` field in k8s CRD spec - # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ - # Such as "project" for the `resourcemanager.googleapis.com/Project` type. - # @!attribute [rw] style - # @return [::Array<::Google::Api::ResourceDescriptor::Style>] - # Style flag(s) for this resource. - # These indicate that a resource is expected to conform to a given - # style. See the specific style flags for additional information. - class ResourceDescriptor - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # A description of the historical or future-looking state of the - # resource pattern. - module History - # The "unset" value. - HISTORY_UNSPECIFIED = 0 - - # The resource originally had one pattern and launched as such, and - # additional patterns were added later. - ORIGINALLY_SINGLE_PATTERN = 1 - - # The resource has one pattern, but the API owner expects to add more - # later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents - # that from being necessary once there are multiple patterns.) - FUTURE_MULTI_PATTERN = 2 - end - - # A flag representing a specific style that a resource claims to conform to. - module Style - # The unspecified value. Do not use. - STYLE_UNSPECIFIED = 0 - - # This resource is intended to be "declarative-friendly". - # - # Declarative-friendly resources must be more strictly consistent, and - # setting this to true communicates to tools that this resource should - # adhere to declarative-friendly expectations. - # - # Note: This is used by the API linter (linter.aip.dev) to enable - # additional checks. - DECLARATIVE_FRIENDLY = 1 - end - end - - # Defines a proto annotation that describes a string field that refers to - # an API resource. - # @!attribute [rw] type - # @return [::String] - # The resource type that the annotated field references. - # - # Example: - # - # message Subscription { - # string topic = 2 [(google.api.resource_reference) = { - # type: "pubsub.googleapis.com/Topic" - # }]; - # } - # - # Occasionally, a field may reference an arbitrary resource. In this case, - # APIs use the special value * in their resource reference. - # - # Example: - # - # message GetIamPolicyRequest { - # string resource = 2 [(google.api.resource_reference) = { - # type: "*" - # }]; - # } - # @!attribute [rw] child_type - # @return [::String] - # The resource type of a child collection that the annotated field - # references. This is useful for annotating the `parent` field that - # doesn't have a fixed resource type. - # - # Example: - # - # message ListLogEntriesRequest { - # string parent = 1 [(google.api.resource_reference) = { - # child_type: "logging.googleapis.com/LogEntry" - # }; - # } - class ResourceReference - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb deleted file mode 100644 index 72dcc5a8c215..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/resources.rb +++ /dev/null @@ -1,1209 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - # An order for GDC hardware. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] display_name - # @return [::String] - # Optional. Display name of this order. - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this order was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this order was last updated. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this order as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [r] state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::State] - # Output only. State of this order. On order creation, state will be set to - # DRAFT. - # @!attribute [rw] organization_contact - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] - # Required. Customer contact information. - # @!attribute [rw] target_workloads - # @return [::Array<::String>] - # Optional. Customer specified workloads of interest targeted by this order. - # This must contain <= 20 elements and the length of each element must be <= - # 50 characters. - # @!attribute [rw] customer_motivation - # @return [::String] - # Required. Information about the customer's motivation for this order. The - # length of this field must be <= 1000 characters. - # @!attribute [rw] fulfillment_time - # @deprecated This field is deprecated and may be removed in the next major version update. - # @return [::Google::Protobuf::Timestamp] - # Deprecated: Please use customer_requested_installation_date instead. - # @!attribute [rw] customer_requested_installation_date - # @return [::Google::Type::Date] - # Optional. Customer requested installation date for this order. - # @!attribute [rw] region_code - # @return [::String] - # Required. [Unicode CLDR](http://cldr.unicode.org/) region code where this - # order will be deployed. For a list of valid CLDR region codes, see the - # [Language Subtag - # Registry](https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry). - # @!attribute [r] order_form_uri - # @return [::String] - # Output only. Link to the order form. - # @!attribute [r] type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::Type] - # Output only. Type of this Order. - # @!attribute [r] submit_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when the order was submitted. Is auto-populated to the - # current time when an order is submitted. - # @!attribute [r] billing_id - # @return [::String] - # Output only. The Google Cloud Billing ID to be charged for this order. - # @!attribute [rw] existing_hardware - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareLocation>] - # Optional. Existing hardware to be removed as part of this order. - # Note: any hardware removed will be recycled unless otherwise agreed. - # @!attribute [r] deployment_type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order::DeploymentType] - # Output only. The deployment type of this order. - # @!attribute [r] actual_installation_date - # @return [::Google::Type::Date] - # Output only. Actual installation date for this order. - # @!attribute [r] estimated_installation_date - # @return [::Google::Type::Date] - # Output only. Estimated installation date for this order. - # @!attribute [r] estimated_delivery_date - # @return [::Google::Type::Date] - # Output only. Estimated delivery date for this order. - # @!attribute [rw] migration - # @return [::Boolean] - # Optional. Whether this order is a migration from customer's existing - # infrastructure. - # @!attribute [r] accepted_time - # @return [::Google::Protobuf::Timestamp] - # Output only. The time when the order was moved to ACCEPTED state. - # @!attribute [r] requested_date_change - # @return [::Google::Type::Date] - # Output only. The date to which the customer or Google wants to set the - # scheduled installation date. - # @!attribute [r] vendor_notes - # @return [::String] - # Output only. Notes for this order, provided by the vendor. - # @!attribute [r] vendor_contact - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] - # Output only. Contact information of the SI assigned to this order. - class Order - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Valid states of an order. - module State - # State of the order is unspecified. - STATE_UNSPECIFIED = 0 - - # Order is being drafted by the customer and has not been submitted yet. - DRAFT = 1 - - # Order has been submitted to Google. - SUBMITTED = 2 - - # All information required from the customer for fulfillment of the order - # is complete. - INFO_COMPLETE = 12 - - # Order has been accepted by Google. - ACCEPTED = 3 - - # Order needs more information from the customer. - ADDITIONAL_INFO_NEEDED = 4 - - # Google has initiated building hardware for the order. - BUILDING = 5 - - # The hardware has been built and is being shipped. - SHIPPING = 6 - - # The hardware is being installed. - INSTALLING = 7 - - # An error occurred in processing the order and customer intervention is - # required. - FAILED = 8 - - # Order has been partially completed i.e., some hardware have been - # delivered and installed. - PARTIALLY_COMPLETED = 9 - - # Order has been completed. - COMPLETED = 10 - - # Order has been cancelled. - CANCELLED = 11 - end - - # Valid types of an Order. - module Type - # Type of the order is unspecified. - TYPE_UNSPECIFIED = 0 - - # Paid by the customer. - PAID = 1 - - # Proof of concept for the customer. - POC = 2 - - # Not billed. - UNPAID = 2 - end - - # Valid types of a deployment. - module DeploymentType - # Deployment type is unspecified. - DEPLOYMENT_TYPE_UNSPECIFIED = 0 - - # Prod deployment with SLOs. - FULL_PRODUCTION = 1 - - # Deployment with best-effort support and no SLOs. - PROOF_OF_CONCEPT = 2 - - # Internal deployment with best-effort support and no SLOs. - INTERNAL = 3 - - # Customer lab deployment that we support as though it's prod. - CUSTOMER_LAB = 4 - end - end - - # A physical site where hardware will be installed. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @!attribute [rw] display_name - # @return [::String] - # Optional. Display name of this Site. - # @!attribute [rw] description - # @return [::String] - # Optional. Description of this Site. - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this site was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this site was last updated. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this site as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [rw] organization_contact - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::OrganizationContact] - # Required. Contact information for this site. - # @!attribute [rw] google_maps_pin_uri - # @return [::String] - # Optional. A URL to the Google Maps address location of the site. - # An example value is `https://goo.gl/maps/xxxxxxxxx`. - # @!attribute [rw] access_times - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::TimePeriod>] - # Optional. The time periods when the site is accessible. - # If this field is empty, the site is accessible at all times. - # - # This field is used by Google to schedule the initial installation as well - # as any later hardware maintenance. You may update this at any time. For - # example, if the initial installation is requested during off-hours but - # maintenance should be performed during regular business hours, you should - # update the access times after initial installation is complete. - # @!attribute [rw] notes - # @return [::String] - # Optional. Any additional notes for this Site. Please include information - # about: - # - security or access restrictions - # - any regulations affecting the technicians visiting the site - # - any special process or approval required to move the equipment - # - whether a representative will be available during site visits - # @!attribute [rw] customer_site_id - # @return [::String] - # Optional. Customer defined identifier for this Site. This can be used to - # identify the site in the customer's own systems. - class Site - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # A group of hardware that is part of the same order, has the same SKU, and is - # delivered to the same site. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this hardware group was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this hardware group was last updated. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this hardware group as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [rw] hardware_count - # @return [::Integer] - # Required. Number of hardware in this HardwareGroup. - # @!attribute [rw] config - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareConfig] - # Required. Configuration for hardware in this HardwareGroup. - # @!attribute [rw] site - # @return [::String] - # Required. Name of the site where the hardware in this HardwareGroup will be - # delivered. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @!attribute [r] state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup::State] - # Output only. Current state of this HardwareGroup. - # @!attribute [rw] zone - # @return [::String] - # Optional. Name of the zone that the hardware in this HardwareGroup belongs - # to. Format: `projects/{project}/locations/{location}/zones/{zone}` - # @!attribute [rw] requested_installation_date - # @deprecated This field is deprecated and may be removed in the next major version update. - # @return [::Google::Type::Date] - # Deprecated: This value is not used. Use the requested_installation_date - # field in the Order resource instead. - class HardwareGroup - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Valid states of a HardwareGroup. - module State - # State of the HardwareGroup is unspecified. - STATE_UNSPECIFIED = 0 - - # More information is required from the customer to make progress. - ADDITIONAL_INFO_NEEDED = 1 - - # Google has initiated building hardware for this HardwareGroup. - BUILDING = 2 - - # The hardware has been built and is being shipped. - SHIPPING = 3 - - # The hardware is being installed. - INSTALLING = 4 - - # Some hardware in the HardwareGroup have been installed. - PARTIALLY_INSTALLED = 5 - - # All hardware in the HardwareGroup have been installed. - INSTALLED = 6 - - # An error occurred and customer intervention is required. - FAILED = 7 - end - end - - # An instance of hardware installed at a site. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # @!attribute [rw] display_name - # @return [::String] - # Optional. Display name for this hardware. - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this hardware was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this hardware was last updated. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this hardware as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [rw] order - # @return [::String] - # Required. Name of the order that this hardware belongs to. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [r] hardware_group - # @return [::String] - # Output only. Name for the hardware group that this hardware belongs to. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @!attribute [rw] site - # @return [::String] - # Required. Name for the site that this hardware belongs to. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @!attribute [r] state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::State] - # Output only. Current state for this hardware. - # @!attribute [r] ciq_uri - # @return [::String] - # Output only. Link to the Customer Intake Questionnaire (CIQ) sheet for this - # Hardware. - # @!attribute [rw] config - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareConfig] - # Required. Configuration for this hardware. - # @!attribute [r] estimated_installation_date - # @return [::Google::Type::Date] - # Output only. Estimated installation date for this hardware. - # @!attribute [rw] physical_info - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo] - # Optional. Physical properties of this hardware. - # @!attribute [rw] installation_info - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareInstallationInfo] - # Optional. Information for installation of this hardware. - # @!attribute [rw] zone - # @return [::String] - # Required. Name for the zone that this hardware belongs to. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @!attribute [rw] requested_installation_date - # @return [::Google::Type::Date] - # Optional. Requested installation date for this hardware. If not specified, - # this is auto-populated from the order's fulfillment_time upon submission or - # from the HardwareGroup's requested_installation_date upon order acceptance. - # @!attribute [r] actual_installation_date - # @return [::Google::Type::Date] - # Output only. Actual installation date for this hardware. Filled in by - # Google. - # @!attribute [r] machine_infos - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MachineInfo>] - # Output only. Per machine asset information needed for turnup. - # @!attribute [r] estimated_delivery_date - # @return [::Google::Type::Date] - # Output only. The estimated delivery date of the hardware. - class Hardware - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Message to describe the MAC address of a machine. - # @!attribute [r] address - # @return [::String] - # Output only. Address string. - # @!attribute [r] type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MacAddress::AddressType] - # Output only. Address type for this MAC address. - # @!attribute [r] ipv4_address - # @return [::String] - # Output only. Static IP address (if used) that is associated with the MAC - # address. Only applicable for VIRTUAL MAC address type. - class MacAddress - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Enum for the different types of MAC address. - module AddressType - # Unspecified address type. - ADDRESS_TYPE_UNSPECIFIED = 0 - - # Address of a network interface card. - NIC = 1 - - # Address of a baseboard management controller. - BMC = 2 - - # Address of a virtual interface. - VIRTUAL = 3 - end - end - - # Information about individual disks on a machine. - # @!attribute [r] manufacturer - # @return [::String] - # Output only. Disk manufacturer. - # @!attribute [r] slot - # @return [::Integer] - # Output only. Disk slot number. - # @!attribute [r] serial_number - # @return [::String] - # Output only. Disk serial number. - # @!attribute [r] psid - # @return [::String] - # Output only. Disk PSID. - # @!attribute [r] part_number - # @return [::String] - # Output only. Disk part number. - # @!attribute [r] model_number - # @return [::String] - # Output only. Disk model number. - class DiskInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Information about individual machines vendors will provide during turnup. - # @!attribute [r] service_tag - # @return [::String] - # Output only. Machine service tag. - # @!attribute [r] mac_addresses - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::MacAddress>] - # Output only. Each associated MAC address. - # @!attribute [r] name - # @return [::String] - # Output only. Machine name. - # @!attribute [r] disk_infos - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware::DiskInfo>] - # Output only. Information for each disk installed. - class MachineInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Valid states for hardware. - module State - # State of the Hardware is unspecified. - STATE_UNSPECIFIED = 0 - - # More information is required from the customer to make progress. - ADDITIONAL_INFO_NEEDED = 1 - - # Google has initiated building hardware for this Hardware. - BUILDING = 2 - - # The hardware has been built and is being shipped. - SHIPPING = 3 - - # The hardware is being installed. - INSTALLING = 4 - - # The hardware has been installed. - INSTALLED = 5 - - # An error occurred and customer intervention is required. - FAILED = 6 - end - end - - # A comment on an order. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this comment was created. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this comment as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [r] author - # @return [::String] - # Output only. Username of the author of this comment. This is auto-populated - # from the credentials used during creation of the comment. - # @!attribute [rw] text - # @return [::String] - # Required. Text of this comment. The length of text must be <= 1000 - # characters. - # @!attribute [r] customer_viewed_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Timestamp of the first time this comment was viewed by the - # customer. If the comment wasn't viewed then this timestamp will be unset. - # @!attribute [r] author_entity - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Entity] - # Output only. The entity the author belongs to. - class Comment - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # A log entry of a change made to an order. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this change log entry. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this change log entry was created. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this change log entry as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [r] log - # @return [::String] - # Output only. Content of this log entry. - class ChangeLogEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - - # A stock keeping unit (SKU) of GDC hardware. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this SKU. - # Format: `projects/{project}/locations/{location}/skus/{sku}` - # @!attribute [r] display_name - # @return [::String] - # Output only. Display name of this SKU. - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this SKU was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this SKU was last updated. - # @!attribute [r] config - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SkuConfig] - # Output only. Configuration for this SKU. - # @!attribute [r] instances - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::SkuInstance>] - # Output only. Available instances of this SKU. This field should be used for - # checking availability of a SKU. - # @!attribute [r] description - # @return [::String] - # Output only. Description of this SKU. - # @!attribute [r] revision_id - # @return [::String] - # Output only. The SKU revision ID. - # A new revision is created whenever `config` is updated. The format is an - # 8-character hexadecimal string. - # @!attribute [r] is_active - # @return [::Boolean] - # Output only. Flag to indicate whether or not this revision is active. Only - # an active revision can be used in a new Order. - # @!attribute [r] type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Sku::Type] - # Output only. Type of this SKU. - # @!attribute [r] vcpu_count - # @return [::Integer] - # Output only. The vCPU count associated with this SKU. - # @!attribute [r] hardware_count_ranges - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku::Range>] - # Output only. The inclusive ranges of hardware counts that are allowed in a - # zone using this SKU. - class Sku - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Inclusive range. - # @!attribute [rw] min - # @return [::Integer] - # The minimum value of the range. - # @!attribute [rw] max - # @return [::Integer] - # The maximum value of the range. - class Range - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Valid types of a SKU. - module Type - # Type of the SKU is unspecified. This is not an allowed value. - TYPE_UNSPECIFIED = 0 - - # Rack SKU. - RACK = 1 - - # Server SKU. - SERVER = 2 - end - end - - # A zone holding a set of hardware. - # @!attribute [rw] name - # @return [::String] - # Identifier. Name of this zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this zone was created. - # @!attribute [r] update_time - # @return [::Google::Protobuf::Timestamp] - # Output only. Time when this zone was last updated. - # @!attribute [rw] labels - # @return [::Google::Protobuf::Map{::String => ::String}] - # Optional. Labels associated with this zone as key value pairs. - # For more information about labels, see [Create and manage - # labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels). - # @!attribute [rw] display_name - # @return [::String] - # Optional. Human friendly display name of this zone. - # @!attribute [r] state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone::State] - # Output only. Current state for this zone. - # @!attribute [rw] contacts - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Contact>] - # Required. The points of contact. - # @!attribute [r] ciq_uri - # @return [::String] - # Output only. Link to the Customer Intake Questionnaire (CIQ) sheet for this - # zone. - # @!attribute [rw] network_config - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::ZoneNetworkConfig] - # Optional. Networking configuration for this zone. - # @!attribute [r] globally_unique_id - # @return [::String] - # Output only. Globally unique identifier generated for this Edge Zone. - # @!attribute [r] subscription_configs - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::SubscriptionConfig>] - # Output only. Subscription configurations for this zone. - # @!attribute [r] provisioning_state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone::ProvisioningState] - # Output only. Provisioning state for configurations like MAC addresses. - # @!attribute [rw] skip_cluster_provisioning - # @return [::Boolean] - # Optional. Whether to skip the cluster provisioning step during factory - # turnup. If true, indicates that the Kubernetes cluster will be created - # after the zone's hardware is installed at the customer site. - # @!attribute [r] cluster_intent_required - # @return [::Boolean] - # Output only. Indicates whether a valid cluster intent must be provided by - # the customer before accepting the order. If true, the order cannot be - # accepted until cluster intent is present. This is used to enforce early - # validation and prevent delays caused by missing configuration. - # @!attribute [r] cluster_intent_verified - # @return [::Boolean] - # Output only. Indicates whether the provided cluster intent has been - # successfully verified. This flag ensures cluster intent exists before order - # can be accepted. - class Zone - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # @!attribute [rw] key - # @return [::String] - # @!attribute [rw] value - # @return [::String] - class LabelsEntry - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Valid states for a zone. - module State - # State of the Zone is unspecified. - STATE_UNSPECIFIED = 0 - - # More information is required from the customer to make progress. - ADDITIONAL_INFO_NEEDED = 1 - - # Google is preparing the Zone. - PREPARING = 2 - - # Factory turnup has succeeded. - READY_FOR_CUSTOMER_FACTORY_TURNUP_CHECKS = 5 - - # The Zone is running factory turnup checks. - CUSTOMER_FACTORY_TURNUP_CHECKS_STARTED = 8 - - # The Zone is ready for site turnup. - READY_FOR_SITE_TURNUP = 6 - - # The Zone is offline. - OFFLINE = 9 - - # The Zone failed in factory turnup checks. - CUSTOMER_FACTORY_TURNUP_CHECKS_FAILED = 7 - - # The Zone is available to use. - ACTIVE = 3 - - # The Zone has been cancelled. - CANCELLED = 4 - end - - # Valid provisioning states for configurations like MAC addresses. - module ProvisioningState - # Provisioning state is unspecified. - PROVISIONING_STATE_UNSPECIFIED = 0 - - # Provisioning is required. Set by Google. - PROVISIONING_REQUIRED = 1 - - # Provisioning is in progress. Set by customer. - PROVISIONING_IN_PROGRESS = 2 - - # Provisioning is complete. Set by customer. - PROVISIONING_COMPLETE = 3 - end - end - - # Contact information of the customer organization. - # @!attribute [rw] address - # @return [::Google::Type::PostalAddress] - # Required. The organization's address. - # @!attribute [rw] email - # @return [::String] - # Optional. The organization's email. - # @!attribute [rw] phone - # @return [::String] - # Optional. The organization's phone number. - # @!attribute [rw] contacts - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Contact>] - # Required. The individual points of contact in the organization at this - # location. - class OrganizationContact - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Contact details of a point of contact. - # @!attribute [rw] given_name - # @return [::String] - # Required. Given name of the contact. - # @!attribute [rw] family_name - # @return [::String] - # Optional. Family name of the contact. - # @!attribute [rw] email - # @return [::String] - # Required. Email of the contact. - # @!attribute [rw] phone - # @return [::String] - # Required. Phone number of the contact. - # @!attribute [rw] time_zone - # @return [::Google::Type::TimeZone] - # Optional. Time zone of the contact. - # @!attribute [rw] reachable_times - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::TimePeriod>] - # Optional. The time periods when the contact is reachable. - # If this field is empty, the contact is reachable at all times. - class Contact - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Configuration for GDC hardware. - # @!attribute [rw] sku - # @return [::String] - # Required. Reference to the SKU for this hardware. This can point to a - # specific SKU revision in the form of `resource_name@revision_id` as defined - # in [AIP-162](https://google.aip.dev/162). If no revision_id is specified, - # it refers to the latest revision. - # @!attribute [rw] power_supply - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::PowerSupply] - # Required. Power supply type for this hardware. - # @!attribute [rw] subscription_duration_months - # @return [::Integer] - # Optional. Subscription duration for the hardware in months. - class HardwareConfig - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Configuration for a SKU. - # @!attribute [rw] cpu - # @return [::String] - # Information about CPU configuration. - # @!attribute [rw] gpu - # @return [::String] - # Information about GPU configuration. - # @!attribute [rw] ram - # @return [::String] - # Information about RAM configuration. - # @!attribute [rw] storage - # @return [::String] - # Information about storage configuration. - class SkuConfig - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A specific instance of the SKU. - # @!attribute [rw] region_code - # @return [::String] - # The [Unicode CLDR](https://cldr.unicode.org) region code where this - # instance is available. - # @!attribute [rw] power_supply - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::PowerSupply] - # Power supply type for this instance. - # @!attribute [rw] billing_sku - # @return [::String] - # Reference to the corresponding SKU in the Cloud Billing API. - # The estimated price information can be retrieved using that API. - # Format: `services/{service}/skus/{sku}` - # @!attribute [rw] billing_sku_per_vcpu - # @return [::String] - # Reference to the corresponding SKU per vCPU in the Cloud Billing API. - # The estimated price information can be retrieved using that API. - # Format: `services/{service}/skus/{sku}` - # @!attribute [rw] subscription_duration_months - # @return [::Integer] - # Subscription duration for the hardware in months. - class SkuInstance - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Physical properties of a hardware. - # @!attribute [rw] power_receptacle - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::PowerReceptacleType] - # Required. The power receptacle type. - # @!attribute [rw] network_uplink - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::NetworkUplinkType] - # Required. Type of the uplink network connection. - # @!attribute [rw] voltage - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::Voltage] - # Required. Voltage of the power supply. - # @!attribute [rw] amperes - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwarePhysicalInfo::Amperes] - # Required. Amperes of the power supply. - class HardwarePhysicalInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Valid power receptacle types. - module PowerReceptacleType - # Facility plug type is unspecified. - POWER_RECEPTACLE_TYPE_UNSPECIFIED = 0 - - # NEMA 5-15. - NEMA_5_15 = 1 - - # C13. - C_13 = 2 - - # Deprecated: Please use TYPE_G_BS1363, CEE_7_3, CEE_7_5 or TYPE_F - # instead. - STANDARD_EU = 3 - - # Type G / BS1363. - TYPE_G_BS1363 = 4 - - # C 7/3. - CEE_7_3 = 5 - - # C 7/5. - CEE_7_5 = 6 - - # Type F. - TYPE_F = 7 - end - - # Valid network uplink types. - module NetworkUplinkType - # Network uplink type is unspecified. - NETWORK_UPLINK_TYPE_UNSPECIFIED = 0 - - # RJ-45. - RJ_45 = 1 - end - - # Valid voltage values. - module Voltage - # Voltage is unspecified. - VOLTAGE_UNSPECIFIED = 0 - - # 120V. - VOLTAGE_110 = 1 - - # 220V. - VOLTAGE_220 = 3 - end - - # Valid amperes values. - module Amperes - # Amperes is unspecified. - AMPERES_UNSPECIFIED = 0 - - # 15A. - AMPERES_15 = 1 - end - end - - # Information for installation of a Hardware. - # @!attribute [rw] rack_location - # @return [::String] - # Required. Location of the rack in the site e.g. Floor 2, Room 201, Row 7, - # Rack 3. - # @!attribute [rw] power_distance_meters - # @return [::Integer] - # Required. Distance from the power outlet in meters. - # @!attribute [rw] switch_distance_meters - # @return [::Integer] - # Required. Distance from the network switch in meters. - # @!attribute [rw] rack_unit_dimensions - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Dimensions] - # Required. Dimensions of the rack unit. - # @!attribute [rw] rack_space - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::RackSpace] - # Required. Rack space allocated for the hardware. - # @!attribute [rw] rack_type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareInstallationInfo::RackType] - # Required. Type of the rack. - class HardwareInstallationInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Valid rack types. - module RackType - # Rack type is unspecified. - RACK_TYPE_UNSPECIFIED = 0 - - # Two post rack. - TWO_POST = 1 - - # Four post rack. - FOUR_POST = 2 - end - end - - # Networking configuration for a zone. - # @!attribute [rw] machine_mgmt_ipv4_range - # @return [::String] - # Required. An IPv4 address block for machine management. - # Should be a private RFC1918 or public CIDR block large enough to allocate - # at least one address per machine in the Zone. - # Should be in `management_ipv4_subnet`, and disjoint with other address - # ranges. - # @!attribute [rw] kubernetes_node_ipv4_range - # @return [::String] - # Required. An IPv4 address block for kubernetes nodes. - # Should be a private RFC1918 or public CIDR block large enough to allocate - # at least one address per machine in the Zone. - # Should be in `kubernetes_ipv4_subnet`, and disjoint with other address - # ranges. - # @!attribute [rw] kubernetes_control_plane_ipv4_range - # @return [::String] - # Required. An IPv4 address block for kubernetes control plane. - # Should be a private RFC1918 or public CIDR block large enough to allocate - # at least one address per cluster in the Zone. - # Should be in `kubernetes_ipv4_subnet`, and disjoint with other address - # ranges. - # @!attribute [rw] management_ipv4_subnet - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Subnet] - # Required. An IPv4 subnet for the management network. - # @!attribute [rw] kubernetes_ipv4_subnet - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Subnet] - # Optional. An IPv4 subnet for the kubernetes network. - # If unspecified, the kubernetes subnet will be the same as the management - # subnet. - # @!attribute [rw] dns_ipv4_addresses - # @return [::Array<::String>] - # Optional. DNS nameservers. - # The GDC Infrastructure will resolve DNS queries via these IPs. - # If unspecified, Google DNS is used. - # @!attribute [rw] kubernetes_primary_vlan_id - # @return [::Integer] - # Optional. Kubernetes VLAN ID. - # By default, the kubernetes node, including the primary kubernetes network, - # are in the same VLAN as the machine management network. - # For network segmentation purposes, these can optionally be separated. - class ZoneNetworkConfig - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents a subnet. - # @!attribute [rw] address_range - # @return [::String] - # Required. Address range for this subnet in CIDR notation. - # @!attribute [rw] default_gateway_ip_address - # @return [::String] - # Required. Default gateway for this subnet. - class Subnet - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents a time period in a week. - # @!attribute [rw] start_time - # @return [::Google::Type::TimeOfDay] - # Required. The start of the time period. - # @!attribute [rw] end_time - # @return [::Google::Type::TimeOfDay] - # Required. The end of the time period. - # @!attribute [rw] days - # @return [::Array<::Google::Type::DayOfWeek>] - # Required. The days of the week that the time period is active. - class TimePeriod - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents the dimensions of an object. - # @!attribute [rw] width_inches - # @return [::Float] - # Required. Width in inches. - # @!attribute [rw] height_inches - # @return [::Float] - # Required. Height in inches. - # @!attribute [rw] depth_inches - # @return [::Float] - # Required. Depth in inches. - class Dimensions - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents contiguous space in a rack. - # @!attribute [rw] start_rack_unit - # @return [::Integer] - # Required. First rack unit of the rack space (inclusive). - # @!attribute [rw] end_rack_unit - # @return [::Integer] - # Required. Last rack unit of the rack space (inclusive). - class RackSpace - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents the location of one or many hardware. - # @!attribute [rw] site - # @return [::String] - # Required. Name of the site where the hardware are present. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @!attribute [rw] rack_location - # @return [::String] - # Required. Location of the rack in the site e.g. Floor 2, Room 201, Row 7, - # Rack 3. - # @!attribute [rw] rack_space - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::RackSpace>] - # Optional. Spaces occupied by the hardware in the rack. - # If unset, this location is assumed to be the entire rack. - class HardwareLocation - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A message to store a subscription configuration. - # @!attribute [r] subscription_id - # @return [::String] - # Output only. The unique identifier of the subscription. - # @!attribute [r] billing_id - # @return [::String] - # Output only. The Google Cloud Billing ID that the subscription is created - # under. - # @!attribute [r] state - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SubscriptionConfig::SubscriptionState] - # Output only. The current state of the subscription. - class SubscriptionConfig - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Enum to represent the state of the subscription. - module SubscriptionState - # State is unspecified. - SUBSCRIPTION_STATE_UNSPECIFIED = 0 - - # Active state means that the subscription has been created successfully - # and billing is happening. - ACTIVE = 1 - - # Inactive means that the subscription has been created successfully, but - # billing has not started yet. - INACTIVE = 2 - - # The subscription is in an erroneous state. - ERROR = 3 - - # The subscription state failed to be retrieved. This may be a transient - # issue. The user should retry the request. - FAILED_TO_RETRIEVE = 4 - - # The subscription has been completed, because it has reached the end date. - COMPLETED = 5 - end - end - - # The power supply options. - module PowerSupply - # Power supply is unspecified. - POWER_SUPPLY_UNSPECIFIED = 0 - - # AC power supply. - POWER_SUPPLY_AC = 1 - - # DC power supply. - POWER_SUPPLY_DC = 2 - end - - # Entity is used to denote an organization or party. - module Entity - # Entity is unspecified. - ENTITY_UNSPECIFIED = 0 - - # Google. - GOOGLE = 1 - - # Customer. - CUSTOMER = 2 - - # Vendor. - VENDOR = 3 - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb deleted file mode 100644 index cf335ddab76c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/cloud/gdchardwaremanagement/v1alpha/service.rb +++ /dev/null @@ -1,959 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Cloud - module GDCHardwareManagement - module V1alpha - # A request to list orders. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to list orders in. - # Format: `projects/{project}/locations/{location}` - # - # To list orders across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListOrdersRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of orders. - # @!attribute [rw] orders - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Order>] - # The list of orders. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. Only used for queries to the wildcard - # location `-`. If non-empty, it indicates that the results are incomplete. - class ListOrdersResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get an order. - # @!attribute [rw] name - # @return [::String] - # Required. Name of the resource - class GetOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create an order. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to create the order in. - # Format: `projects/{project}/locations/{location}` - # @!attribute [rw] order_id - # @return [::String] - # Optional. ID used to uniquely identify the Order within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The order.name field in the request will be ignored. - # @!attribute [rw] order - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # Required. The order to create. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CreateOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to update an order. - # @!attribute [rw] update_mask - # @return [::Google::Protobuf::FieldMask] - # Required. A mask to specify the fields in the Order to overwrite with this - # update. The fields specified in the update_mask are relative to the order, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @!attribute [rw] order - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Order] - # Required. The order to update. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class UpdateOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to delete an order. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @!attribute [rw] force - # @return [::Boolean] - # Optional. An option to delete any nested resources in the Order, such as a - # HardwareGroup. If true, any nested resources for this Order will also be - # deleted. Otherwise, the request will only succeed if the Order has no - # nested resources. - class DeleteOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to submit an order. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @!attribute [rw] type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest::Type] - # Optional. Type of this request. If unset, the request type is assumed to be - # `INFO_PENDING`. - class SubmitOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Valid types of submit order request. - module Type - # Request type is unspecified. This should not be used. - TYPE_UNSPECIFIED = 0 - - # Use this request type to submit your order and initiate conversation with - # Google. After this submission, you will not be able to modify the number - # or SKU of your ordered hardware. Please note that this order will not be - # ready for fulfillment yet until you provide more information, such as - # zone network configuration, hardware physical and installation - # information, etc. - # If you are submitting an order for a SKU type of RACK, please use this - # request type, as additional information will be required outside of the - # API. - INFO_PENDING = 1 - - # Use this request type if and when you are ready to submit your order for - # fulfillment. In addition to the information required for `INFO_PENDING`, - # the order must contain all required information, such as zone network - # configuration, hardware physical and installation information, etc. - # Further changes to any order information will no longer be allowed. - INFO_COMPLETE = 2 - end - end - - # A request to cancel an order. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the order. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CancelOrderRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list sites. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to list sites in. - # Format: `projects/{project}/locations/{location}` - # - # To list sites across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListSitesRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of sites. - # @!attribute [rw] sites - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Site>] - # The list of sites. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. Only used for queries to the wildcard - # location `-`. If non-empty, it indicates that the results are incomplete. - class ListSitesResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get a site. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - class GetSiteRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create a site. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to create the site in. - # Format: `projects/{project}/locations/{location}` - # @!attribute [rw] site_id - # @return [::String] - # Optional. ID used to uniquely identify the Site within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The site.name field in the request will be ignored. - # @!attribute [rw] site - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # Required. The site to create. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CreateSiteRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to update a site. - # @!attribute [rw] update_mask - # @return [::Google::Protobuf::FieldMask] - # Required. A mask to specify the fields in the Site to overwrite with this - # update. The fields specified in the update_mask are relative to the site, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @!attribute [rw] site - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Site] - # Required. The site to update. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class UpdateSiteRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to delete a site. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the site. - # Format: `projects/{project}/locations/{location}/sites/{site}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class DeleteSiteRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list hardware groups. - # @!attribute [rw] parent - # @return [::String] - # Required. The order to list hardware groups in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListHardwareGroupsRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of hardware groups. - # @!attribute [rw] hardware_groups - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup>] - # The list of hardware groups. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. - class ListHardwareGroupsResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get a hardware group. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - class GetHardwareGroupRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create a hardware group. - # @!attribute [rw] parent - # @return [::String] - # Required. The order to create the hardware group in. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] hardware_group_id - # @return [::String] - # Optional. ID used to uniquely identify the HardwareGroup within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware_group.name field in the request will be ignored. - # @!attribute [rw] hardware_group - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # Required. The hardware group to create. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CreateHardwareGroupRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to update a hardware group. - # @!attribute [rw] update_mask - # @return [::Google::Protobuf::FieldMask] - # Required. A mask to specify the fields in the HardwareGroup to overwrite - # with this update. The fields specified in the update_mask are relative to - # the hardware group, not the full request. A field will be overwritten if it - # is in the mask. If you don't provide a mask then all fields will be - # overwritten. - # @!attribute [rw] hardware_group - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup] - # Required. The hardware group to update. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class UpdateHardwareGroupRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to delete a hardware group. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the hardware group. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/hardwareGroups/{hardware_group}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class DeleteHardwareGroupRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list hardware. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to list hardware in. - # Format: `projects/{project}/locations/{location}` - # - # To list hardware across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListHardwareRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of hardware. - # @!attribute [rw] hardware - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware>] - # The list of hardware. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. Only used for queries to the wildcard - # location `-`. If non-empty, it indicates that the results are incomplete. - class ListHardwareResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get hardware. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - class GetHardwareRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create hardware. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to create hardware in. - # Format: `projects/{project}/locations/{location}` - # @!attribute [rw] hardware_id - # @return [::String] - # Optional. ID used to uniquely identify the Hardware within its parent - # scope. This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The hardware.name field in the request will be ignored. - # @!attribute [rw] hardware - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # Required. The resource to create. - class CreateHardwareRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to update hardware. - # @!attribute [rw] update_mask - # @return [::Google::Protobuf::FieldMask] - # Required. A mask to specify the fields in the Hardware to overwrite with - # this update. The fields specified in the update_mask are relative to the - # hardware, not the full request. A field will be overwritten if it is in the - # mask. If you don't provide a mask then all fields will be overwritten. - # @!attribute [rw] hardware - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware] - # Required. The hardware to update. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class UpdateHardwareRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to delete hardware. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the hardware. - # Format: `projects/{project}/locations/{location}/hardware/{hardware}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class DeleteHardwareRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list comments. - # @!attribute [rw] parent - # @return [::String] - # Required. The order to list comments on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListCommentsRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list comments. - # @!attribute [rw] comments - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Comment>] - # The list of comments. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. - class ListCommentsResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get a comment. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - class GetCommentRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create a comment. - # @!attribute [rw] parent - # @return [::String] - # Required. The order to create the comment on. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] comment_id - # @return [::String] - # Optional. ID used to uniquely identify the Comment within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The comment.name field in the request will be ignored. - # @!attribute [rw] comment - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Comment] - # Required. The comment to create. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CreateCommentRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to record an action on a comment. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the comment. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/comments/{comment}` - # @!attribute [rw] action_type - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest::ActionType] - # Required. The action type of the recorded action. - class RecordActionOnCommentRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Valid action types of Comment. - module ActionType - # Action is unspecified. - ACTION_TYPE_UNSPECIFIED = 0 - - # Mark comment as read. - READ = 1 - - # Mark comment as unread. - UNREAD = 2 - end - end - - # A request to list change log entries. - # @!attribute [rw] parent - # @return [::String] - # Required. The order to list change log entries for. - # Format: `projects/{project}/locations/{location}/orders/{order}` - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListChangeLogEntriesRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of change log entries. - # @!attribute [rw] change_log_entries - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry>] - # The list of change log entries. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. - class ListChangeLogEntriesResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get a change log entry. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the change log entry. - # Format: - # `projects/{project}/locations/{location}/orders/{order}/changeLogEntries/{change_log_entry}` - class GetChangeLogEntryRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list SKUs. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to list SKUs in. - # Format: `projects/{project}/locations/{location}` - # - # To list SKUs across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListSkusRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of SKUs. - # @!attribute [rw] skus - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Sku>] - # The list of SKUs. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. Only used for queries to the wildcard - # location `-`. If non-empty, it indicates that the results are incomplete. - class ListSkusResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get an SKU. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the SKU. - # Format: `projects/{project}/locations/{location}/skus/{sku}` - class GetSkuRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to list zones. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to list zones in. - # Format: `projects/{project}/locations/{location}` - # - # To list zones across all locations, substitute `-` (the hyphen or - # dash character) for the location and check the unreachable field in - # the response message. - # @!attribute [rw] page_size - # @return [::Integer] - # Optional. Requested page size. Server may return fewer items than - # requested. If unspecified, server will pick an appropriate default. - # @!attribute [rw] page_token - # @return [::String] - # Optional. A token identifying a page of results the server should return. - # @!attribute [rw] filter - # @return [::String] - # Optional. Filtering condition. See [AIP-160](https://google.aip.dev/160). - # @!attribute [rw] order_by - # @return [::String] - # Optional. Hint for how to order the results. - class ListZonesRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A list of zones. - # @!attribute [rw] zones - # @return [::Array<::Google::Cloud::GDCHardwareManagement::V1alpha::Zone>] - # The list of zones. - # @!attribute [rw] next_page_token - # @return [::String] - # A token identifying a page of results the server should return. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Locations that could not be reached. Only used for queries to the wildcard - # location `-`. If non-empty, it indicates that the results are incomplete. - class ListZonesResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to get a zone. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - class GetZoneRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to create a zone. - # @!attribute [rw] parent - # @return [::String] - # Required. The project and location to create the zone in. - # Format: `projects/{project}/locations/{location}` - # @!attribute [rw] zone_id - # @return [::String] - # Optional. ID used to uniquely identify the Zone within its parent scope. - # This field should contain at most 63 characters and must start with - # lowercase characters. - # Only lowercase characters, numbers and `-` are accepted. - # The `-` character cannot be the first or the last one. - # A system generated ID will be used if the field is not set. - # - # The zone.name field in the request will be ignored. - # @!attribute [rw] zone - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # Required. The zone to create. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class CreateZoneRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to update a zone. - # @!attribute [rw] update_mask - # @return [::Google::Protobuf::FieldMask] - # Required. A mask to specify the fields in the Zone to overwrite with this - # update. The fields specified in the update_mask are relative to the zone, - # not the full request. A field will be overwritten if it is in the mask. If - # you don't provide a mask then all fields will be overwritten. - # @!attribute [rw] zone - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::Zone] - # Required. The zone to update. - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class UpdateZoneRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to delete a zone. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - class DeleteZoneRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to signal the state of a zone. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the zone. - # Format: `projects/{project}/locations/{location}/zones/{zone}` - # @!attribute [rw] request_id - # @return [::String] - # Optional. An optional unique identifier for this request. See - # [AIP-155](https://google.aip.dev/155). - # @!attribute [rw] state_signal - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::StateSignal] - # Optional. The state signal to send for this zone. Either state_signal or - # provisioning_state_signal must be set, but not both. - # @!attribute [rw] provisioning_state_signal - # @return [::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest::ProvisioningStateSignal] - # Optional. The provisioning state signal to send for this zone. Either - # state_signal or provisioning_state_signal must be set, but not both. - # @!attribute [rw] step - # @return [::String] - # Optional. The step being executed. Provides a finer grained status when the - # state_signal is FACTORY_TURNUP_CHECKS_STARTED or - # FACTORY_TURNUP_CHECKS_FAILED. - # @!attribute [rw] details - # @return [::String] - # Optional. Additional details, such as an error message when state_signal is - # FACTORY_TURNUP_CHECKS_FAILED. - class SignalZoneStateRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - - # Valid state signals for a zone. - module StateSignal - # State signal of the zone is unspecified. - STATE_SIGNAL_UNSPECIFIED = 0 - - # Factory turnup checks have started. - FACTORY_TURNUP_CHECKS_STARTED = 3 - - # The Zone is ready for site turnup. - FACTORY_TURNUP_CHECKS_PASSED = 1 - - # The Zone is ready for site turnup. Deprecated, but not deleted. - READY_FOR_SITE_TURNUP = 1 - - # The Zone failed in factory turnup checks. - FACTORY_TURNUP_CHECKS_FAILED = 2 - - # Verify that a valid cluster intent is present. - VERIFY_CLUSTER_INTENT_PRESENCE = 4 - end - - # Valid provisioning state signals for a zone. - module ProvisioningStateSignal - # Provisioning state signal is unspecified. - PROVISIONING_STATE_SIGNAL_UNSPECIFIED = 0 - - # Provisioning is in progress. - PROVISIONING_IN_PROGRESS = 1 - - # Provisioning is complete. - PROVISIONING_COMPLETE = 2 - end - end - - # Represents the metadata of a long-running operation. - # @!attribute [r] create_time - # @return [::Google::Protobuf::Timestamp] - # Output only. The time the operation was created. - # @!attribute [r] end_time - # @return [::Google::Protobuf::Timestamp] - # Output only. The time the operation finished running. - # @!attribute [r] target - # @return [::String] - # Output only. Server-defined resource path for the target of the operation. - # @!attribute [r] verb - # @return [::String] - # Output only. The verb executed by the operation. - # @!attribute [r] status_message - # @return [::String] - # Output only. Human-readable status of the operation, if any. - # @!attribute [r] requested_cancellation - # @return [::Boolean] - # Output only. Identifies whether the user has requested cancellation - # of the operation. Operations that have been cancelled successfully - # have [Operation.error][] value with a - # {::Google::Rpc::Status#code google.rpc.Status.code} of 1, corresponding to - # `Code.CANCELLED`. - # @!attribute [r] api_version - # @return [::String] - # Output only. API version used to start the operation. - class OperationMetadata - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A request to change the requested date of an order. - # @!attribute [rw] name - # @return [::String] - # Required. The name of the order to update. - # Format: projects/\\{project}/locations/\\{location}/orders/\\{order} - # @!attribute [rw] requested_date - # @return [::Google::Type::Date] - # Required. The date to which the customer or Google wants to set the - # scheduled installation date. - class RequestOrderDateChangeRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb deleted file mode 100644 index 7a757f512165..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/longrunning/operations.rb +++ /dev/null @@ -1,191 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Longrunning - # This resource represents a long-running operation that is the result of a - # network API call. - # @!attribute [rw] name - # @return [::String] - # The server-assigned name, which is only unique within the same service that - # originally returns it. If you use the default HTTP mapping, the - # `name` should be a resource name ending with `operations/{unique_id}`. - # @!attribute [rw] metadata - # @return [::Google::Protobuf::Any] - # Service-specific metadata associated with the operation. It typically - # contains progress information and common metadata such as create time. - # Some services might not provide such metadata. Any method that returns a - # long-running operation should document the metadata type, if any. - # @!attribute [rw] done - # @return [::Boolean] - # If the value is `false`, it means the operation is still in progress. - # If `true`, the operation is completed, and either `error` or `response` is - # available. - # @!attribute [rw] error - # @return [::Google::Rpc::Status] - # The error result of the operation in case of failure or cancellation. - # - # Note: The following fields are mutually exclusive: `error`, `response`. If a field in that set is populated, all other fields in the set will automatically be cleared. - # @!attribute [rw] response - # @return [::Google::Protobuf::Any] - # The normal, successful response of the operation. If the original - # method returns no data on success, such as `Delete`, the response is - # `google.protobuf.Empty`. If the original method is standard - # `Get`/`Create`/`Update`, the response should be the resource. For other - # methods, the response should have the type `XxxResponse`, where `Xxx` - # is the original method name. For example, if the original method name - # is `TakeSnapshot()`, the inferred response type is - # `TakeSnapshotResponse`. - # - # Note: The following fields are mutually exclusive: `response`, `error`. If a field in that set is populated, all other fields in the set will automatically be cleared. - class Operation - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The request message for - # Operations.GetOperation. - # @!attribute [rw] name - # @return [::String] - # The name of the operation resource. - class GetOperationRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The request message for - # Operations.ListOperations. - # @!attribute [rw] name - # @return [::String] - # The name of the operation's parent resource. - # @!attribute [rw] filter - # @return [::String] - # The standard list filter. - # @!attribute [rw] page_size - # @return [::Integer] - # The standard list page size. - # @!attribute [rw] page_token - # @return [::String] - # The standard list page token. - # @!attribute [rw] return_partial_success - # @return [::Boolean] - # When set to `true`, operations that are reachable are returned as normal, - # and those that are unreachable are returned in the - # [ListOperationsResponse.unreachable] field. - # - # This can only be `true` when reading across collections e.g. when `parent` - # is set to `"projects/example/locations/-"`. - # - # This field is not by default supported and will result in an - # `UNIMPLEMENTED` error if set unless explicitly documented otherwise in - # service or product specific documentation. - class ListOperationsRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The response message for - # Operations.ListOperations. - # @!attribute [rw] operations - # @return [::Array<::Google::Longrunning::Operation>] - # A list of operations that matches the specified filter in the request. - # @!attribute [rw] next_page_token - # @return [::String] - # The standard List next-page token. - # @!attribute [rw] unreachable - # @return [::Array<::String>] - # Unordered list. Unreachable resources. Populated when the request sets - # `ListOperationsRequest.return_partial_success` and reads across - # collections e.g. when attempting to list all resources across all supported - # locations. - class ListOperationsResponse - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The request message for - # Operations.CancelOperation. - # @!attribute [rw] name - # @return [::String] - # The name of the operation resource to be cancelled. - class CancelOperationRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The request message for - # Operations.DeleteOperation. - # @!attribute [rw] name - # @return [::String] - # The name of the operation resource to be deleted. - class DeleteOperationRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # The request message for - # Operations.WaitOperation. - # @!attribute [rw] name - # @return [::String] - # The name of the operation resource to wait on. - # @!attribute [rw] timeout - # @return [::Google::Protobuf::Duration] - # The maximum duration to wait before timing out. If left blank, the wait - # will be at most the time permitted by the underlying HTTP/RPC protocol. - # If RPC context deadline is also specified, the shorter one will be used. - class WaitOperationRequest - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # A message representing the message types used by a long-running operation. - # - # Example: - # - # rpc Export(ExportRequest) returns (google.longrunning.Operation) { - # option (google.longrunning.operation_info) = { - # response_type: "ExportResponse" - # metadata_type: "ExportMetadata" - # }; - # } - # @!attribute [rw] response_type - # @return [::String] - # Required. The message name of the primary return type for this - # long-running operation. - # This type will be used to deserialize the LRO's response. - # - # If the response is in a different package from the rpc, a fully-qualified - # message name must be used (e.g. `google.protobuf.Struct`). - # - # Note: Altering this value constitutes a breaking change. - # @!attribute [rw] metadata_type - # @return [::String] - # Required. The message name of the metadata type for this long-running - # operation. - # - # If the response is in a different package from the rpc, a fully-qualified - # message name must be used (e.g. `google.protobuf.Struct`). - # - # Note: Altering this value constitutes a breaking change. - class OperationInfo - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb deleted file mode 100644 index 58691995f02e..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/any.rb +++ /dev/null @@ -1,145 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Protobuf - # `Any` contains an arbitrary serialized protocol buffer message along with a - # URL that describes the type of the serialized message. - # - # Protobuf library provides support to pack/unpack Any values in the form - # of utility functions or additional generated methods of the Any type. - # - # Example 1: Pack and unpack a message in C++. - # - # Foo foo = ...; - # Any any; - # any.PackFrom(foo); - # ... - # if (any.UnpackTo(&foo)) { - # ... - # } - # - # Example 2: Pack and unpack a message in Java. - # - # Foo foo = ...; - # Any any = Any.pack(foo); - # ... - # if (any.is(Foo.class)) { - # foo = any.unpack(Foo.class); - # } - # // or ... - # if (any.isSameTypeAs(Foo.getDefaultInstance())) { - # foo = any.unpack(Foo.getDefaultInstance()); - # } - # - # Example 3: Pack and unpack a message in Python. - # - # foo = Foo(...) - # any = Any() - # any.Pack(foo) - # ... - # if any.Is(Foo.DESCRIPTOR): - # any.Unpack(foo) - # ... - # - # Example 4: Pack and unpack a message in Go - # - # foo := &pb.Foo{...} - # any, err := anypb.New(foo) - # if err != nil { - # ... - # } - # ... - # foo := &pb.Foo{} - # if err := any.UnmarshalTo(foo); err != nil { - # ... - # } - # - # The pack methods provided by protobuf library will by default use - # 'type.googleapis.com/full.type.name' as the type URL and the unpack - # methods only use the fully qualified type name after the last '/' - # in the type URL, for example "foo.bar.com/x/y.z" will yield type - # name "y.z". - # - # JSON - # ==== - # The JSON representation of an `Any` value uses the regular - # representation of the deserialized, embedded message, with an - # additional field `@type` which contains the type URL. Example: - # - # package google.profile; - # message Person { - # string first_name = 1; - # string last_name = 2; - # } - # - # { - # "@type": "type.googleapis.com/google.profile.Person", - # "firstName": , - # "lastName": - # } - # - # If the embedded message type is well-known and has a custom JSON - # representation, that representation will be embedded adding a field - # `value` which holds the custom JSON in addition to the `@type` - # field. Example (for message [google.protobuf.Duration][]): - # - # { - # "@type": "type.googleapis.com/google.protobuf.Duration", - # "value": "1.212s" - # } - # @!attribute [rw] type_url - # @return [::String] - # A URL/resource name that uniquely identifies the type of the serialized - # protocol buffer message. This string must contain at least - # one "/" character. The last segment of the URL's path must represent - # the fully qualified name of the type (as in - # `path/google.protobuf.Duration`). The name should be in a canonical form - # (e.g., leading "." is not accepted). - # - # In practice, teams usually precompile into the binary all types that they - # expect it to use in the context of Any. However, for URLs which use the - # scheme `http`, `https`, or no scheme, one can optionally set up a type - # server that maps type URLs to message definitions as follows: - # - # * If no scheme is provided, `https` is assumed. - # * An HTTP GET on the URL must yield a [google.protobuf.Type][] - # value in binary format, or produce an error. - # * Applications are allowed to cache lookup results based on the - # URL, or have them precompiled into a binary to avoid any - # lookup. Therefore, binary compatibility needs to be preserved - # on changes to types. (Use versioned type names to manage - # breaking changes.) - # - # Note: this functionality is not currently available in the official - # protobuf release, and it is not used for type URLs beginning with - # type.googleapis.com. As of May 2023, there are no widely used type server - # implementations and no plans to implement one. - # - # Schemes other than `http`, `https` (or the empty scheme) might be - # used with implementation specific semantics. - # @!attribute [rw] value - # @return [::String] - # Must be a valid serialized protocol buffer of the above specified type. - class Any - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb deleted file mode 100644 index ea59f1f91daf..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/duration.rb +++ /dev/null @@ -1,98 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Protobuf - # A Duration represents a signed, fixed-length span of time represented - # as a count of seconds and fractions of seconds at nanosecond - # resolution. It is independent of any calendar and concepts like "day" - # or "month". It is related to Timestamp in that the difference between - # two Timestamp values is a Duration and it can be added or subtracted - # from a Timestamp. Range is approximately +-10,000 years. - # - # # Examples - # - # Example 1: Compute Duration from two Timestamps in pseudo code. - # - # Timestamp start = ...; - # Timestamp end = ...; - # Duration duration = ...; - # - # duration.seconds = end.seconds - start.seconds; - # duration.nanos = end.nanos - start.nanos; - # - # if (duration.seconds < 0 && duration.nanos > 0) { - # duration.seconds += 1; - # duration.nanos -= 1000000000; - # } else if (duration.seconds > 0 && duration.nanos < 0) { - # duration.seconds -= 1; - # duration.nanos += 1000000000; - # } - # - # Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. - # - # Timestamp start = ...; - # Duration duration = ...; - # Timestamp end = ...; - # - # end.seconds = start.seconds + duration.seconds; - # end.nanos = start.nanos + duration.nanos; - # - # if (end.nanos < 0) { - # end.seconds -= 1; - # end.nanos += 1000000000; - # } else if (end.nanos >= 1000000000) { - # end.seconds += 1; - # end.nanos -= 1000000000; - # } - # - # Example 3: Compute Duration from datetime.timedelta in Python. - # - # td = datetime.timedelta(days=3, minutes=10) - # duration = Duration() - # duration.FromTimedelta(td) - # - # # JSON Mapping - # - # In JSON format, the Duration type is encoded as a string rather than an - # object, where the string ends in the suffix "s" (indicating seconds) and - # is preceded by the number of seconds, with nanoseconds expressed as - # fractional seconds. For example, 3 seconds with 0 nanoseconds should be - # encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should - # be expressed in JSON format as "3.000000001s", and 3 seconds and 1 - # microsecond should be expressed in JSON format as "3.000001s". - # @!attribute [rw] seconds - # @return [::Integer] - # Signed seconds of the span of time. Must be from -315,576,000,000 - # to +315,576,000,000 inclusive. Note: these bounds are computed from: - # 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years - # @!attribute [rw] nanos - # @return [::Integer] - # Signed fractions of a second at nanosecond resolution of the span - # of time. Durations less than one second are represented with a 0 - # `seconds` field and a positive or negative `nanos` field. For durations - # of one second or more, a non-zero value for the `nanos` field must be - # of the same sign as the `seconds` field. Must be from -999,999,999 - # to +999,999,999 inclusive. - class Duration - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb deleted file mode 100644 index 83e4481834a6..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/empty.rb +++ /dev/null @@ -1,34 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Protobuf - # A generic empty message that you can re-use to avoid defining duplicated - # empty messages in your APIs. A typical example is to use it as the request - # or the response type of an API method. For instance: - # - # service Foo { - # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); - # } - class Empty - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb deleted file mode 100644 index 7f3ffc78601a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/field_mask.rb +++ /dev/null @@ -1,229 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Protobuf - # `FieldMask` represents a set of symbolic field paths, for example: - # - # paths: "f.a" - # paths: "f.b.d" - # - # Here `f` represents a field in some root message, `a` and `b` - # fields in the message found in `f`, and `d` a field found in the - # message in `f.b`. - # - # Field masks are used to specify a subset of fields that should be - # returned by a get operation or modified by an update operation. - # Field masks also have a custom JSON encoding (see below). - # - # # Field Masks in Projections - # - # When used in the context of a projection, a response message or - # sub-message is filtered by the API to only contain those fields as - # specified in the mask. For example, if the mask in the previous - # example is applied to a response message as follows: - # - # f { - # a : 22 - # b { - # d : 1 - # x : 2 - # } - # y : 13 - # } - # z: 8 - # - # The result will not contain specific values for fields x,y and z - # (their value will be set to the default, and omitted in proto text - # output): - # - # - # f { - # a : 22 - # b { - # d : 1 - # } - # } - # - # A repeated field is not allowed except at the last position of a - # paths string. - # - # If a FieldMask object is not present in a get operation, the - # operation applies to all fields (as if a FieldMask of all fields - # had been specified). - # - # Note that a field mask does not necessarily apply to the - # top-level response message. In case of a REST get operation, the - # field mask applies directly to the response, but in case of a REST - # list operation, the mask instead applies to each individual message - # in the returned resource list. In case of a REST custom method, - # other definitions may be used. Where the mask applies will be - # clearly documented together with its declaration in the API. In - # any case, the effect on the returned resource/resources is required - # behavior for APIs. - # - # # Field Masks in Update Operations - # - # A field mask in update operations specifies which fields of the - # targeted resource are going to be updated. The API is required - # to only change the values of the fields as specified in the mask - # and leave the others untouched. If a resource is passed in to - # describe the updated values, the API ignores the values of all - # fields not covered by the mask. - # - # If a repeated field is specified for an update operation, new values will - # be appended to the existing repeated field in the target resource. Note that - # a repeated field is only allowed in the last position of a `paths` string. - # - # If a sub-message is specified in the last position of the field mask for an - # update operation, then new value will be merged into the existing sub-message - # in the target resource. - # - # For example, given the target message: - # - # f { - # b { - # d: 1 - # x: 2 - # } - # c: [1] - # } - # - # And an update message: - # - # f { - # b { - # d: 10 - # } - # c: [2] - # } - # - # then if the field mask is: - # - # paths: ["f.b", "f.c"] - # - # then the result will be: - # - # f { - # b { - # d: 10 - # x: 2 - # } - # c: [1, 2] - # } - # - # An implementation may provide options to override this default behavior for - # repeated and message fields. - # - # In order to reset a field's value to the default, the field must - # be in the mask and set to the default value in the provided resource. - # Hence, in order to reset all fields of a resource, provide a default - # instance of the resource and set all fields in the mask, or do - # not provide a mask as described below. - # - # If a field mask is not present on update, the operation applies to - # all fields (as if a field mask of all fields has been specified). - # Note that in the presence of schema evolution, this may mean that - # fields the client does not know and has therefore not filled into - # the request will be reset to their default. If this is unwanted - # behavior, a specific service may require a client to always specify - # a field mask, producing an error if not. - # - # As with get operations, the location of the resource which - # describes the updated values in the request message depends on the - # operation kind. In any case, the effect of the field mask is - # required to be honored by the API. - # - # ## Considerations for HTTP REST - # - # The HTTP kind of an update operation which uses a field mask must - # be set to PATCH instead of PUT in order to satisfy HTTP semantics - # (PUT must only be used for full updates). - # - # # JSON Encoding of Field Masks - # - # In JSON, a field mask is encoded as a single string where paths are - # separated by a comma. Fields name in each path are converted - # to/from lower-camel naming conventions. - # - # As an example, consider the following message declarations: - # - # message Profile { - # User user = 1; - # Photo photo = 2; - # } - # message User { - # string display_name = 1; - # string address = 2; - # } - # - # In proto a field mask for `Profile` may look as such: - # - # mask { - # paths: "user.display_name" - # paths: "photo" - # } - # - # In JSON, the same mask is represented as below: - # - # { - # mask: "user.displayName,photo" - # } - # - # # Field Masks and Oneof Fields - # - # Field masks treat fields in oneofs just as regular fields. Consider the - # following message: - # - # message SampleMessage { - # oneof test_oneof { - # string name = 4; - # SubMessage sub_message = 9; - # } - # } - # - # The field mask can be: - # - # mask { - # paths: "name" - # } - # - # Or: - # - # mask { - # paths: "sub_message" - # } - # - # Note that oneof type names ("test_oneof" in this case) cannot be used in - # paths. - # - # ## Field Mask Verification - # - # The implementation of any API method which has a FieldMask type field in the - # request should verify the included field paths, and return an - # `INVALID_ARGUMENT` error if any path is unmappable. - # @!attribute [rw] paths - # @return [::Array<::String>] - # The set of field mask paths. - class FieldMask - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb deleted file mode 100644 index 74352be9c58c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/protobuf/timestamp.rb +++ /dev/null @@ -1,127 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Protobuf - # A Timestamp represents a point in time independent of any time zone or local - # calendar, encoded as a count of seconds and fractions of seconds at - # nanosecond resolution. The count is relative to an epoch at UTC midnight on - # January 1, 1970, in the proleptic Gregorian calendar which extends the - # Gregorian calendar backwards to year one. - # - # All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap - # second table is needed for interpretation, using a [24-hour linear - # smear](https://developers.google.com/time/smear). - # - # The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By - # restricting to that range, we ensure that we can convert to and from [RFC - # 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. - # - # # Examples - # - # Example 1: Compute Timestamp from POSIX `time()`. - # - # Timestamp timestamp; - # timestamp.set_seconds(time(NULL)); - # timestamp.set_nanos(0); - # - # Example 2: Compute Timestamp from POSIX `gettimeofday()`. - # - # struct timeval tv; - # gettimeofday(&tv, NULL); - # - # Timestamp timestamp; - # timestamp.set_seconds(tv.tv_sec); - # timestamp.set_nanos(tv.tv_usec * 1000); - # - # Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. - # - # FILETIME ft; - # GetSystemTimeAsFileTime(&ft); - # UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; - # - # // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z - # // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. - # Timestamp timestamp; - # timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); - # timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); - # - # Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. - # - # long millis = System.currentTimeMillis(); - # - # Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) - # .setNanos((int) ((millis % 1000) * 1000000)).build(); - # - # Example 5: Compute Timestamp from Java `Instant.now()`. - # - # Instant now = Instant.now(); - # - # Timestamp timestamp = - # Timestamp.newBuilder().setSeconds(now.getEpochSecond()) - # .setNanos(now.getNano()).build(); - # - # Example 6: Compute Timestamp from current time in Python. - # - # timestamp = Timestamp() - # timestamp.GetCurrentTime() - # - # # JSON Mapping - # - # In JSON format, the Timestamp type is encoded as a string in the - # [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the - # format is "\\{year}-\\{month}-\\{day}T\\{hour}:\\{min}:\\{sec}[.\\{frac_sec}]Z" - # where \\{year} is always expressed using four digits while \\{month}, \\{day}, - # \\{hour}, \\{min}, and \\{sec} are zero-padded to two digits each. The fractional - # seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution), - # are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone - # is required. A proto3 JSON serializer should always use UTC (as indicated by - # "Z") when printing the Timestamp type and a proto3 JSON parser should be - # able to accept both UTC and other timezones (as indicated by an offset). - # - # For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past - # 01:30 UTC on January 15, 2017. - # - # In JavaScript, one can convert a Date object to this format using the - # standard - # [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) - # method. In Python, a standard `datetime.datetime` object can be converted - # to this format using - # [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with - # the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use - # the Joda Time's [`ISODateTimeFormat.dateTime()`]( - # http://joda-time.sourceforge.net/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime() - # ) to obtain a formatter capable of generating timestamps in this format. - # @!attribute [rw] seconds - # @return [::Integer] - # Represents seconds of UTC time since Unix epoch - # 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to - # 9999-12-31T23:59:59Z inclusive. - # @!attribute [rw] nanos - # @return [::Integer] - # Non-negative fractions of a second at nanosecond resolution. Negative - # second values with fractions must still have non-negative nanos values - # that count forward in time. Must be from 0 to 999,999,999 - # inclusive. - class Timestamp - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb deleted file mode 100644 index c1a1c07eb2db..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/rpc/status.rb +++ /dev/null @@ -1,48 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Rpc - # The `Status` type defines a logical error model that is suitable for - # different programming environments, including REST APIs and RPC APIs. It is - # used by [gRPC](https://github.com/grpc). Each `Status` message contains - # three pieces of data: error code, error message, and error details. - # - # You can find out more about this error model and how to work with it in the - # [API Design Guide](https://cloud.google.com/apis/design/errors). - # @!attribute [rw] code - # @return [::Integer] - # The status code, which should be an enum value of - # [google.rpc.Code][google.rpc.Code]. - # @!attribute [rw] message - # @return [::String] - # A developer-facing error message, which should be in English. Any - # user-facing error message should be localized and sent in the - # {::Google::Rpc::Status#details google.rpc.Status.details} field, or localized - # by the client. - # @!attribute [rw] details - # @return [::Array<::Google::Protobuf::Any>] - # A list of messages that carry the error details. There is a common set of - # message types for APIs to use. - class Status - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb deleted file mode 100644 index 14ec426522d9..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/date.rb +++ /dev/null @@ -1,53 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Type - # Represents a whole or partial calendar date, such as a birthday. The time of - # day and time zone are either specified elsewhere or are insignificant. The - # date is relative to the Gregorian Calendar. This can represent one of the - # following: - # - # * A full date, with non-zero year, month, and day values - # * A month and day value, with a zero year, such as an anniversary - # * A year on its own, with zero month and day values - # * A year and month value, with a zero day, such as a credit card expiration - # date - # - # Related types are {::Google::Type::TimeOfDay google.type.TimeOfDay} and - # `google.protobuf.Timestamp`. - # @!attribute [rw] year - # @return [::Integer] - # Year of the date. Must be from 1 to 9999, or 0 to specify a date without - # a year. - # @!attribute [rw] month - # @return [::Integer] - # Month of a year. Must be from 1 to 12, or 0 to specify a year without a - # month and day. - # @!attribute [rw] day - # @return [::Integer] - # Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 - # to specify a year by itself or a year and month where the day isn't - # significant. - class Date - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb deleted file mode 100644 index d15ba7af54e4..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/datetime.rb +++ /dev/null @@ -1,103 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Type - # Represents civil time (or occasionally physical time). - # - # This type can represent a civil time in one of a few possible ways: - # - # * When utc_offset is set and time_zone is unset: a civil time on a calendar - # day with a particular offset from UTC. - # * When time_zone is set and utc_offset is unset: a civil time on a calendar - # day in a particular time zone. - # * When neither time_zone nor utc_offset is set: a civil time on a calendar - # day in local time. - # - # The date is relative to the Proleptic Gregorian Calendar. - # - # If year is 0, the DateTime is considered not to have a specific year. month - # and day must have valid, non-zero values. - # - # This type may also be used to represent a physical time if all the date and - # time fields are set and either case of the `time_offset` oneof is set. - # Consider using `Timestamp` message for physical time instead. If your use - # case also would like to store the user's timezone, that can be done in - # another field. - # - # This type is more flexible than some applications may want. Make sure to - # document and validate your application's limitations. - # @!attribute [rw] year - # @return [::Integer] - # Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a - # datetime without a year. - # @!attribute [rw] month - # @return [::Integer] - # Required. Month of year. Must be from 1 to 12. - # @!attribute [rw] day - # @return [::Integer] - # Required. Day of month. Must be from 1 to 31 and valid for the year and - # month. - # @!attribute [rw] hours - # @return [::Integer] - # Required. Hours of day in 24 hour format. Should be from 0 to 23. An API - # may choose to allow the value "24:00:00" for scenarios like business - # closing time. - # @!attribute [rw] minutes - # @return [::Integer] - # Required. Minutes of hour of day. Must be from 0 to 59. - # @!attribute [rw] seconds - # @return [::Integer] - # Required. Seconds of minutes of the time. Must normally be from 0 to 59. An - # API may allow the value 60 if it allows leap-seconds. - # @!attribute [rw] nanos - # @return [::Integer] - # Required. Fractions of seconds in nanoseconds. Must be from 0 to - # 999,999,999. - # @!attribute [rw] utc_offset - # @return [::Google::Protobuf::Duration] - # UTC offset. Must be whole seconds, between -18 hours and +18 hours. - # For example, a UTC offset of -4:00 would be represented as - # { seconds: -14400 }. - # - # Note: The following fields are mutually exclusive: `utc_offset`, `time_zone`. If a field in that set is populated, all other fields in the set will automatically be cleared. - # @!attribute [rw] time_zone - # @return [::Google::Type::TimeZone] - # Time zone. - # - # Note: The following fields are mutually exclusive: `time_zone`, `utc_offset`. If a field in that set is populated, all other fields in the set will automatically be cleared. - class DateTime - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - - # Represents a time zone from the - # [IANA Time Zone Database](https://www.iana.org/time-zones). - # @!attribute [rw] id - # @return [::String] - # IANA Time Zone Database time zone, e.g. "America/New_York". - # @!attribute [rw] version - # @return [::String] - # Optional. IANA Time Zone Database version number, e.g. "2019a". - class TimeZone - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb deleted file mode 100644 index 973211b9ffe7..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/dayofweek.rb +++ /dev/null @@ -1,49 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Type - # Represents a day of the week. - module DayOfWeek - # The day of the week is unspecified. - DAY_OF_WEEK_UNSPECIFIED = 0 - - # Monday - MONDAY = 1 - - # Tuesday - TUESDAY = 2 - - # Wednesday - WEDNESDAY = 3 - - # Thursday - THURSDAY = 4 - - # Friday - FRIDAY = 5 - - # Saturday - SATURDAY = 6 - - # Sunday - SUNDAY = 7 - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb deleted file mode 100644 index 9cd0c16495dd..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/postal_address.rb +++ /dev/null @@ -1,135 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Type - # Represents a postal address, e.g. for postal delivery or payments addresses. - # Given a postal address, a postal service can deliver items to a premise, P.O. - # Box or similar. - # It is not intended to model geographical locations (roads, towns, - # mountains). - # - # In typical usage an address would be created via user input or from importing - # existing data, depending on the type of process. - # - # Advice on address input / editing: - # - Use an i18n-ready address widget such as - # https://github.com/google/libaddressinput) - # - Users should not be presented with UI elements for input or editing of - # fields outside countries where that field is used. - # - # For more guidance on how to use this schema, please see: - # https://support.google.com/business/answer/6397478 - # @!attribute [rw] revision - # @return [::Integer] - # The schema revision of the `PostalAddress`. This must be set to 0, which is - # the latest revision. - # - # All new revisions **must** be backward compatible with old revisions. - # @!attribute [rw] region_code - # @return [::String] - # Required. CLDR region code of the country/region of the address. This - # is never inferred and it is up to the user to ensure the value is - # correct. See http://cldr.unicode.org/ and - # http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html - # for details. Example: "CH" for Switzerland. - # @!attribute [rw] language_code - # @return [::String] - # Optional. BCP-47 language code of the contents of this address (if - # known). This is often the UI language of the input form or is expected - # to match one of the languages used in the address' country/region, or their - # transliterated equivalents. - # This can affect formatting in certain countries, but is not critical - # to the correctness of the data and will never affect any validation or - # other non-formatting related operations. - # - # If this value is not known, it should be omitted (rather than specifying a - # possibly incorrect default). - # - # Examples: "zh-Hant", "ja", "ja-Latn", "en". - # @!attribute [rw] postal_code - # @return [::String] - # Optional. Postal code of the address. Not all countries use or require - # postal codes to be present, but where they are used, they may trigger - # additional validation with other parts of the address (e.g. state/zip - # validation in the U.S.A.). - # @!attribute [rw] sorting_code - # @return [::String] - # Optional. Additional, country-specific, sorting code. This is not used - # in most regions. Where it is used, the value is either a string like - # "CEDEX", optionally followed by a number (e.g. "CEDEX 7"), or just a number - # alone, representing the "sector code" (Jamaica), "delivery area indicator" - # (Malawi) or "post office indicator" (e.g. CĂ´te d'Ivoire). - # @!attribute [rw] administrative_area - # @return [::String] - # Optional. Highest administrative subdivision which is used for postal - # addresses of a country or region. - # For example, this can be a state, a province, an oblast, or a prefecture. - # Specifically, for Spain this is the province and not the autonomous - # community (e.g. "Barcelona" and not "Catalonia"). - # Many countries don't use an administrative area in postal addresses. E.g. - # in Switzerland this should be left unpopulated. - # @!attribute [rw] locality - # @return [::String] - # Optional. Generally refers to the city/town portion of the address. - # Examples: US city, IT comune, UK post town. - # In regions of the world where localities are not well defined or do not fit - # into this structure well, leave locality empty and use address_lines. - # @!attribute [rw] sublocality - # @return [::String] - # Optional. Sublocality of the address. - # For example, this can be neighborhoods, boroughs, districts. - # @!attribute [rw] address_lines - # @return [::Array<::String>] - # Unstructured address lines describing the lower levels of an address. - # - # Because values in address_lines do not have type information and may - # sometimes contain multiple values in a single field (e.g. - # "Austin, TX"), it is important that the line order is clear. The order of - # address lines should be "envelope order" for the country/region of the - # address. In places where this can vary (e.g. Japan), address_language is - # used to make it explicit (e.g. "ja" for large-to-small ordering and - # "ja-Latn" or "en" for small-to-large). This way, the most specific line of - # an address can be selected based on the language. - # - # The minimum permitted structural representation of an address consists - # of a region_code with all remaining information placed in the - # address_lines. It would be possible to format such an address very - # approximately without geocoding, but no semantic reasoning could be - # made about any of the address components until it was at least - # partially resolved. - # - # Creating an address only containing a region_code and address_lines, and - # then geocoding is the recommended way to handle completely unstructured - # addresses (as opposed to guessing which parts of the address should be - # localities or administrative areas). - # @!attribute [rw] recipients - # @return [::Array<::String>] - # Optional. The recipient at the address. - # This field may, under certain circumstances, contain multiline information. - # For example, it might contain "care of" information. - # @!attribute [rw] organization - # @return [::String] - # Optional. The name of the organization at the address. - class PostalAddress - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb deleted file mode 100644 index b0c888c8c14a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/proto_docs/google/type/timeofday.rb +++ /dev/null @@ -1,45 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - - -module Google - module Type - # Represents a time of day. The date and time zone are either not significant - # or are specified elsewhere. An API may choose to allow leap seconds. Related - # types are {::Google::Type::Date google.type.Date} and - # `google.protobuf.Timestamp`. - # @!attribute [rw] hours - # @return [::Integer] - # Hours of day in 24 hour format. Should be from 0 to 23. An API may choose - # to allow the value "24:00:00" for scenarios like business closing time. - # @!attribute [rw] minutes - # @return [::Integer] - # Minutes of hour of day. Must be from 0 to 59. - # @!attribute [rw] seconds - # @return [::Integer] - # Seconds of minutes of the time. Must normally be from 0 to 59. An API may - # allow the value 60 if it allows leap-seconds. - # @!attribute [rw] nanos - # @return [::Integer] - # Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999. - class TimeOfDay - include ::Google::Protobuf::MessageExts - extend ::Google::Protobuf::MessageExts::ClassMethods - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile deleted file mode 100644 index bc4dfa6ce8bb..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/Gemfile +++ /dev/null @@ -1,32 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -source "https://rubygems.org" - -if ENV["GOOGLE_CLOUD_SAMPLES_TEST"] == "master" - gem "google-cloud-gdc_hardware_management-v1alpha", path: "../" -else - gem "google-cloud-gdc_hardware_management-v1alpha" -end - -group :test do - gem "google-style", "~> 1.26.1" - gem "minitest", "~> 5.16" - gem "minitest-focus", "~> 1.1" - gem "minitest-hooks", "~> 1.5" -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb deleted file mode 100644 index e5bd5c423c3b..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/cancel_order.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the cancel_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order. -# -def cancel_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new - - # Call the cancel_order method. - result = client.cancel_order request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb deleted file mode 100644 index 062eb7e3ef99..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_comment.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_comment call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment. -# -def create_comment - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new - - # Call the create_comment method. - result = client.create_comment request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb deleted file mode 100644 index c32bad4e6a94..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_hardware call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware. -# -def create_hardware - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new - - # Call the create_hardware method. - result = client.create_hardware request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb deleted file mode 100644 index 50d51125fa19..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_hardware_group.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_hardware_group call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group. -# -def create_hardware_group - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new - - # Call the create_hardware_group method. - result = client.create_hardware_group request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb deleted file mode 100644 index 8c945f8aa66e..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_order.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order. -# -def create_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new - - # Call the create_order method. - result = client.create_order request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb deleted file mode 100644 index 7e1b922105b5..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_site.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_site call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site. -# -def create_site - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new - - # Call the create_site method. - result = client.create_site request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb deleted file mode 100644 index 4651805796c6..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/create_zone.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the create_zone call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone. -# -def create_zone - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new - - # Call the create_zone method. - result = client.create_zone request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb deleted file mode 100644 index e26abc148d39..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the delete_hardware call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware. -# -def delete_hardware - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new - - # Call the delete_hardware method. - result = client.delete_hardware request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb deleted file mode 100644 index 57375279b7b7..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_hardware_group.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the delete_hardware_group call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group. -# -def delete_hardware_group - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new - - # Call the delete_hardware_group method. - result = client.delete_hardware_group request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb deleted file mode 100644 index 2e6a508f59c6..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_order.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the delete_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order. -# -def delete_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new - - # Call the delete_order method. - result = client.delete_order request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb deleted file mode 100644 index 1f66ee279ec0..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_site.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the delete_site call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site. -# -def delete_site - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new - - # Call the delete_site method. - result = client.delete_site request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb deleted file mode 100644 index 6928b1a8ce3f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/delete_zone.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the delete_zone call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone. -# -def delete_zone - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new - - # Call the delete_zone method. - result = client.delete_zone request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb deleted file mode 100644 index 79c9468fa048..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_change_log_entry.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_change_log_entry call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry. -# -def get_change_log_entry - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new - - # Call the get_change_log_entry method. - result = client.get_change_log_entry request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb deleted file mode 100644 index daf60605d6ad..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_comment.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_comment call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment. -# -def get_comment - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new - - # Call the get_comment method. - result = client.get_comment request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb deleted file mode 100644 index 6a4cdf59e3dc..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_hardware call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware. -# -def get_hardware - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new - - # Call the get_hardware method. - result = client.get_hardware request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb deleted file mode 100644 index 029aa4e5843f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_hardware_group.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_hardware_group call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group. -# -def get_hardware_group - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new - - # Call the get_hardware_group method. - result = client.get_hardware_group request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb deleted file mode 100644 index 57af00353628..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_order.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order. -# -def get_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new - - # Call the get_order method. - result = client.get_order request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Order. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb deleted file mode 100644 index 26c42c9b8c06..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_site.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_site call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site. -# -def get_site - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new - - # Call the get_site method. - result = client.get_site request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Site. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb deleted file mode 100644 index cbf346bbb908..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_sku.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_sku call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku. -# -def get_sku - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new - - # Call the get_sku method. - result = client.get_sku request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb deleted file mode 100644 index 7f966c999986..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/get_zone.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the get_zone call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone. -# -def get_zone - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new - - # Call the get_zone method. - result = client.get_zone request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb deleted file mode 100644 index 233c809f62cb..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_change_log_entries.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_change_log_entries call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries. -# -def list_change_log_entries - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new - - # Call the list_change_log_entries method. - result = client.list_change_log_entries request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb deleted file mode 100644 index d262606f7295..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_comments.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_comments call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments. -# -def list_comments - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new - - # Call the list_comments method. - result = client.list_comments request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb deleted file mode 100644 index 43d212bbdabf..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_hardware call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware. -# -def list_hardware - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new - - # Call the list_hardware method. - result = client.list_hardware request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb deleted file mode 100644 index ff05fedcd54c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_hardware_groups.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_hardware_groups call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups. -# -def list_hardware_groups - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new - - # Call the list_hardware_groups method. - result = client.list_hardware_groups request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb deleted file mode 100644 index 93864a8f35f2..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_orders.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_orders call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders. -# -def list_orders - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new - - # Call the list_orders method. - result = client.list_orders request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Order. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb deleted file mode 100644 index b60a042059fb..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_sites.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_sites call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites. -# -def list_sites - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new - - # Call the list_sites method. - result = client.list_sites request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Site. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb deleted file mode 100644 index 909dbe2038eb..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_skus.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_skus call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus. -# -def list_skus - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new - - # Call the list_skus method. - result = client.list_skus request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb deleted file mode 100644 index bea66ba9bc2f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/list_zones.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the list_zones call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones. -# -def list_zones - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new - - # Call the list_zones method. - result = client.list_zones request - - # The returned object is of type Gapic::PagedEnumerable. You can iterate - # over elements, and API calls will be issued to fetch pages as needed. - result.each do |item| - # Each element is of type ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone. - p item - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb deleted file mode 100644 index 5a00e3446e6a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/record_action_on_comment.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the record_action_on_comment call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment. -# -def record_action_on_comment - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new - - # Call the record_action_on_comment method. - result = client.record_action_on_comment request - - # The returned object is of type Google::Cloud::GDCHardwareManagement::V1alpha::Comment. - p result -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb deleted file mode 100644 index 723bf8387b20..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/request_order_date_change.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the request_order_date_change call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change. -# -def request_order_date_change - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new - - # Call the request_order_date_change method. - result = client.request_order_date_change request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb deleted file mode 100644 index 70f0d340ff17..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/signal_zone_state.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the signal_zone_state call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state. -# -def signal_zone_state - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new - - # Call the signal_zone_state method. - result = client.signal_zone_state request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb deleted file mode 100644 index 93d353c3f9bd..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/submit_order.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the submit_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order. -# -def submit_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new - - # Call the submit_order method. - result = client.submit_order request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb deleted file mode 100644 index c40036ffab3c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the update_hardware call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware. -# -def update_hardware - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new - - # Call the update_hardware method. - result = client.update_hardware request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb deleted file mode 100644 index 2b813dfc0196..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_hardware_group.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the update_hardware_group call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group. -# -def update_hardware_group - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new - - # Call the update_hardware_group method. - result = client.update_hardware_group request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb deleted file mode 100644 index 75de15ad44ff..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_order.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the update_order call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order. -# -def update_order - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new - - # Call the update_order method. - result = client.update_order request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb deleted file mode 100644 index afa54b028217..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_site.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the update_site call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site. -# -def update_site - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new - - # Call the update_site method. - result = client.update_site request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb deleted file mode 100644 index fd3682f19c7c..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/gdc_hardware_management/update_zone.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -# [START gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync] -require "google/cloud/gdc_hardware_management/v1alpha" - -## -# Snippet for the update_zone call in the GDCHardwareManagement service -# -# This snippet has been automatically generated and should be regarded as a code -# template only. It will require modifications to work: -# - It may require correct/in-range values for request initialization. -# - It may require specifying regional endpoints when creating the service -# client as shown in https://cloud.google.com/ruby/docs/reference. -# -# This is an auto-generated example demonstrating basic usage of -# Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone. -# -def update_zone - # Create a client object. The client can be reused for multiple calls. - client = Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new - - # Create a request. To set request fields, pass in keyword arguments. - request = Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new - - # Call the update_zone method. - result = client.update_zone request - - # The returned object is of type Gapic::Operation. You can use it to - # check the status of an operation, cancel it, or wait for results. - # Here is how to wait for a response. - result.wait_until_done! timeout: 60 - if result.response? - p result.response - else - puts "No response received." - end -end -# [END gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync] diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json deleted file mode 100644 index bec0bf6c87e3..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/snippets/snippet_metadata_google.cloud.gdchardwaremanagement.v1alpha.json +++ /dev/null @@ -1,1495 +0,0 @@ -{ - "client_library": { - "name": "google-cloud-gdc_hardware_management-v1alpha", - "version": "", - "language": "RUBY", - "apis": [ - { - "id": "google.cloud.gdchardwaremanagement.v1alpha", - "version": "v1alpha" - } - ] - }, - "snippets": [ - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListOrders_sync", - "title": "Snippet for the list_orders call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders.", - "file": "gdc_hardware_management/list_orders.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_orders", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_orders", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListOrders", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListOrders", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetOrder_sync", - "title": "Snippet for the get_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order.", - "file": "gdc_hardware_management/get_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Order", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateOrder_sync", - "title": "Snippet for the create_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order.", - "file": "gdc_hardware_management/create_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateOrder_sync", - "title": "Snippet for the update_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order.", - "file": "gdc_hardware_management/update_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "update_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "UpdateOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteOrder_sync", - "title": "Snippet for the delete_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order.", - "file": "gdc_hardware_management/delete_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "delete_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "DeleteOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SubmitOrder_sync", - "title": "Snippet for the submit_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order.", - "file": "gdc_hardware_management/submit_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "submit_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#submit_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "SubmitOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.SubmitOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CancelOrder_sync", - "title": "Snippet for the cancel_order call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order.", - "file": "gdc_hardware_management/cancel_order.rb", - "language": "RUBY", - "client_method": { - "short_name": "cancel_order", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#cancel_order", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CancelOrder", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CancelOrder", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSites_sync", - "title": "Snippet for the list_sites call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites.", - "file": "gdc_hardware_management/list_sites.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_sites", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_sites", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListSites", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListSites", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSite_sync", - "title": "Snippet for the get_site call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site.", - "file": "gdc_hardware_management/get_site.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_site", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_site", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Site", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetSite", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetSite", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateSite_sync", - "title": "Snippet for the create_site call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site.", - "file": "gdc_hardware_management/create_site.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_site", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_site", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateSite", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateSite", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateSite_sync", - "title": "Snippet for the update_site call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site.", - "file": "gdc_hardware_management/update_site.rb", - "language": "RUBY", - "client_method": { - "short_name": "update_site", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_site", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "UpdateSite", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateSite", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteSite_sync", - "title": "Snippet for the delete_site call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site.", - "file": "gdc_hardware_management/delete_site.rb", - "language": "RUBY", - "client_method": { - "short_name": "delete_site", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_site", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "DeleteSite", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteSite", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardwareGroups_sync", - "title": "Snippet for the list_hardware_groups call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups.", - "file": "gdc_hardware_management/list_hardware_groups.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_hardware_groups", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware_groups", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListHardwareGroups", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListHardwareGroups", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardwareGroup_sync", - "title": "Snippet for the get_hardware_group call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group.", - "file": "gdc_hardware_management/get_hardware_group.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_hardware_group", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware_group", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetHardwareGroup", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetHardwareGroup", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardwareGroup_sync", - "title": "Snippet for the create_hardware_group call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group.", - "file": "gdc_hardware_management/create_hardware_group.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_hardware_group", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware_group", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateHardwareGroup", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateHardwareGroup", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardwareGroup_sync", - "title": "Snippet for the update_hardware_group call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group.", - "file": "gdc_hardware_management/update_hardware_group.rb", - "language": "RUBY", - "client_method": { - "short_name": "update_hardware_group", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware_group", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "UpdateHardwareGroup", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateHardwareGroup", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardwareGroup_sync", - "title": "Snippet for the delete_hardware_group call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group.", - "file": "gdc_hardware_management/delete_hardware_group.rb", - "language": "RUBY", - "client_method": { - "short_name": "delete_hardware_group", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware_group", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "DeleteHardwareGroup", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteHardwareGroup", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListHardware_sync", - "title": "Snippet for the list_hardware call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware.", - "file": "gdc_hardware_management/list_hardware.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_hardware", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_hardware", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListHardware", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListHardware", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetHardware_sync", - "title": "Snippet for the get_hardware call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware.", - "file": "gdc_hardware_management/get_hardware.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_hardware", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_hardware", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetHardware", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetHardware", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateHardware_sync", - "title": "Snippet for the create_hardware call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware.", - "file": "gdc_hardware_management/create_hardware.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_hardware", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_hardware", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateHardware", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateHardware", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateHardware_sync", - "title": "Snippet for the update_hardware call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware.", - "file": "gdc_hardware_management/update_hardware.rb", - "language": "RUBY", - "client_method": { - "short_name": "update_hardware", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_hardware", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "UpdateHardware", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateHardware", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteHardware_sync", - "title": "Snippet for the delete_hardware call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware.", - "file": "gdc_hardware_management/delete_hardware.rb", - "language": "RUBY", - "client_method": { - "short_name": "delete_hardware", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_hardware", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "DeleteHardware", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteHardware", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListComments_sync", - "title": "Snippet for the list_comments call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments.", - "file": "gdc_hardware_management/list_comments.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_comments", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_comments", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListComments", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListComments", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetComment_sync", - "title": "Snippet for the get_comment call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment.", - "file": "gdc_hardware_management/get_comment.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_comment", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_comment", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Comment", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetComment", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetComment", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateComment_sync", - "title": "Snippet for the create_comment call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment.", - "file": "gdc_hardware_management/create_comment.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_comment", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_comment", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateComment", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateComment", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RecordActionOnComment_sync", - "title": "Snippet for the record_action_on_comment call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment.", - "file": "gdc_hardware_management/record_action_on_comment.rb", - "language": "RUBY", - "client_method": { - "short_name": "record_action_on_comment", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#record_action_on_comment", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Comment", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "RecordActionOnComment", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.RecordActionOnComment", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListChangeLogEntries_sync", - "title": "Snippet for the list_change_log_entries call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries.", - "file": "gdc_hardware_management/list_change_log_entries.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_change_log_entries", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_change_log_entries", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListChangeLogEntries", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListChangeLogEntries", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetChangeLogEntry_sync", - "title": "Snippet for the get_change_log_entry call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry.", - "file": "gdc_hardware_management/get_change_log_entry.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_change_log_entry", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_change_log_entry", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetChangeLogEntry", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetChangeLogEntry", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListSkus_sync", - "title": "Snippet for the list_skus call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus.", - "file": "gdc_hardware_management/list_skus.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_skus", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_skus", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListSkus", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListSkus", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetSku_sync", - "title": "Snippet for the get_sku call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku.", - "file": "gdc_hardware_management/get_sku.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_sku", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_sku", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Sku", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetSku", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetSku", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_ListZones_sync", - "title": "Snippet for the list_zones call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones.", - "file": "gdc_hardware_management/list_zones.rb", - "language": "RUBY", - "client_method": { - "short_name": "list_zones", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#list_zones", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "ListZones", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.ListZones", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 50, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_GetZone_sync", - "title": "Snippet for the get_zone call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone.", - "file": "gdc_hardware_management/get_zone.rb", - "language": "RUBY", - "client_method": { - "short_name": "get_zone", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#get_zone", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest", - "name": "request" - } - ], - "result_type": "::Google::Cloud::GDCHardwareManagement::V1alpha::Zone", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "GetZone", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.GetZone", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 46, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_CreateZone_sync", - "title": "Snippet for the create_zone call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone.", - "file": "gdc_hardware_management/create_zone.rb", - "language": "RUBY", - "client_method": { - "short_name": "create_zone", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#create_zone", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "CreateZone", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.CreateZone", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_UpdateZone_sync", - "title": "Snippet for the update_zone call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone.", - "file": "gdc_hardware_management/update_zone.rb", - "language": "RUBY", - "client_method": { - "short_name": "update_zone", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#update_zone", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "UpdateZone", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.UpdateZone", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_DeleteZone_sync", - "title": "Snippet for the delete_zone call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone.", - "file": "gdc_hardware_management/delete_zone.rb", - "language": "RUBY", - "client_method": { - "short_name": "delete_zone", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#delete_zone", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "DeleteZone", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.DeleteZone", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_SignalZoneState_sync", - "title": "Snippet for the signal_zone_state call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state.", - "file": "gdc_hardware_management/signal_zone_state.rb", - "language": "RUBY", - "client_method": { - "short_name": "signal_zone_state", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#signal_zone_state", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "SignalZoneState", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.SignalZoneState", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - }, - { - "region_tag": "gdchardwaremanagement_v1alpha_generated_GDCHardwareManagement_RequestOrderDateChange_sync", - "title": "Snippet for the request_order_date_change call in the GDCHardwareManagement service", - "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change.", - "file": "gdc_hardware_management/request_order_date_change.rb", - "language": "RUBY", - "client_method": { - "short_name": "request_order_date_change", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client#request_order_date_change", - "async": false, - "parameters": [ - { - "type": "::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest", - "name": "request" - } - ], - "result_type": "::Google::Longrunning::Operation", - "client": { - "short_name": "GDCHardwareManagement::Client", - "full_name": "::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client" - }, - "method": { - "short_name": "RequestOrderDateChange", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement.RequestOrderDateChange", - "service": { - "short_name": "GDCHardwareManagement", - "full_name": "google.cloud.gdchardwaremanagement.v1alpha.GDCHardwareManagement" - } - } - }, - "canonical": true, - "origin": "API_DEFINITION", - "segments": [ - { - "start": 20, - "end": 53, - "type": "FULL" - } - ] - } - ] -} \ No newline at end of file diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb deleted file mode 100644 index 84f131151d1f..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_operations_test.rb +++ /dev/null @@ -1,400 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "helper" - -require "gapic/grpc/service_stub" - -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" -require "google/cloud/gdchardwaremanagement/v1alpha/service_services_pb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" - -class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::OperationsTest < Minitest::Test - class ClientStub - attr_accessor :call_rpc_count, :requests - - def initialize response, operation, &block - @response = response - @operation = operation - @block = block - @call_rpc_count = 0 - @requests = [] - end - - def call_rpc *args, **kwargs - @call_rpc_count += 1 - - @requests << @block&.call(*args, **kwargs) - - catch :response do - yield @response, @operation if block_given? - @response - end - end - - def endpoint - "endpoint.example.com" - end - - def universe_domain - "example.com" - end - - def stub_logger - nil - end - - def logger - nil - end - end - - def test_list_operations - # Create GRPC objects. - grpc_response = ::Google::Longrunning::ListOperationsResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - filter = "hello world" - page_size = 42 - page_token = "hello world" - return_partial_success = true - - list_operations_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_operations, name - assert_kind_of ::Google::Longrunning::ListOperationsRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["filter"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal true, request["return_partial_success"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_operations_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_operations({ name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_operations name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_operations ::Google::Longrunning::ListOperationsRequest.new(name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_operations({ name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_operations(::Google::Longrunning::ListOperationsRequest.new(name: name, filter: filter, page_size: page_size, page_token: page_token, return_partial_success: return_partial_success), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_operations_client_stub.call_rpc_count - end - end - - def test_get_operation - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_operation, name - assert_kind_of ::Google::Longrunning::GetOperationRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_operation_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_operation({ name: name }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_operation name: name do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_operation ::Google::Longrunning::GetOperationRequest.new(name: name) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_operation({ name: name }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_operation(::Google::Longrunning::GetOperationRequest.new(name: name), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_operation_client_stub.call_rpc_count - end - end - - def test_delete_operation - # Create GRPC objects. - grpc_response = ::Google::Protobuf::Empty.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - delete_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_operation, name - assert_kind_of ::Google::Longrunning::DeleteOperationRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_operation_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_operation({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_operation name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_operation ::Google::Longrunning::DeleteOperationRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_operation({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_operation(::Google::Longrunning::DeleteOperationRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_operation_client_stub.call_rpc_count - end - end - - def test_cancel_operation - # Create GRPC objects. - grpc_response = ::Google::Protobuf::Empty.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - cancel_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :cancel_operation, name - assert_kind_of ::Google::Longrunning::CancelOperationRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, cancel_operation_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.cancel_operation({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.cancel_operation name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.cancel_operation ::Google::Longrunning::CancelOperationRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.cancel_operation({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.cancel_operation(::Google::Longrunning::CancelOperationRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, cancel_operation_client_stub.call_rpc_count - end - end - - def test_wait_operation - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - timeout = {} - - wait_operation_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :wait_operation, name - assert_kind_of ::Google::Longrunning::WaitOperationRequest, request - assert_equal "hello world", request["name"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::Duration), request["timeout"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, wait_operation_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.wait_operation({ name: name, timeout: timeout }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.wait_operation name: name, timeout: timeout do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.wait_operation ::Google::Longrunning::WaitOperationRequest.new(name: name, timeout: timeout) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.wait_operation({ name: name, timeout: timeout }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.wait_operation(::Google::Longrunning::WaitOperationRequest.new(name: name, timeout: timeout), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, wait_operation_client_stub.call_rpc_count - end - end - - def test_configure - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - - client = block_config = config = nil - dummy_stub = ClientStub.new nil, nil - Gapic::ServiceStub.stub :new, dummy_stub do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations.new do |config| - config.credentials = grpc_channel - end - end - - config = client.configure do |c| - block_config = c - end - - assert_same block_config, config - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations::Configuration, config - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb deleted file mode 100644 index b4561b9b4999..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_paths_test.rb +++ /dev/null @@ -1,151 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "helper" - -require "gapic/grpc/service_stub" - -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" - -class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::ClientPathsTest < Minitest::Test - class DummyStub - def endpoint - "endpoint.example.com" - end - - def universe_domain - "example.com" - end - - def stub_logger - nil - end - - def logger - nil - end - end - - def test_change_log_entry_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.change_log_entry_path project: "value0", location: "value1", order: "value2", change_log_entry: "value3" - assert_equal "projects/value0/locations/value1/orders/value2/changeLogEntries/value3", path - end - end - - def test_comment_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.comment_path project: "value0", location: "value1", order: "value2", comment: "value3" - assert_equal "projects/value0/locations/value1/orders/value2/comments/value3", path - end - end - - def test_hardware_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.hardware_path project: "value0", location: "value1", hardware: "value2" - assert_equal "projects/value0/locations/value1/hardware/value2", path - end - end - - def test_hardware_group_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.hardware_group_path project: "value0", location: "value1", order: "value2", hardware_group: "value3" - assert_equal "projects/value0/locations/value1/orders/value2/hardwareGroups/value3", path - end - end - - def test_location_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.location_path project: "value0", location: "value1" - assert_equal "projects/value0/locations/value1", path - end - end - - def test_order_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.order_path project: "value0", location: "value1", order: "value2" - assert_equal "projects/value0/locations/value1/orders/value2", path - end - end - - def test_site_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.site_path project: "value0", location: "value1", site: "value2" - assert_equal "projects/value0/locations/value1/sites/value2", path - end - end - - def test_sku_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.sku_path project: "value0", location: "value1", sku: "value2" - assert_equal "projects/value0/locations/value1/skus/value2", path - end - end - - def test_zone_path - grpc_channel = ::GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - ::Gapic::ServiceStub.stub :new, DummyStub.new do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - path = client.zone_path project: "value0", location: "value1", zone: "value2" - assert_equal "projects/value0/locations/value1/zones/value2", path - end - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb deleted file mode 100644 index 2af55a6e9488..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_rest_test.rb +++ /dev/null @@ -1,2172 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "helper" -require "gapic/rest" -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management/rest" - - -class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ClientTest < Minitest::Test - class ClientStub - attr_accessor :call_count, :requests - - def initialize response, &block - @response = response - @block = block - @call_count = 0 - @requests = [] - end - - def make_get_request uri:, params: {}, options: {}, method_name: nil - make_http_request :get, uri: uri, body: nil, params: params, options: options, method_name: method_name - end - - def make_delete_request uri:, params: {}, options: {}, method_name: nil - make_http_request :delete, uri: uri, body: nil, params: params, options: options, method_name: method_name - end - - def make_post_request uri:, body: nil, params: {}, options: {}, method_name: nil - make_http_request :post, uri: uri, body: body, params: params, options: options, method_name: method_name - end - - def make_patch_request uri:, body:, params: {}, options: {}, method_name: nil - make_http_request :patch, uri: uri, body: body, params: params, options: options, method_name: method_name - end - - def make_put_request uri:, body:, params: {}, options: {}, method_name: nil - make_http_request :put, uri: uri, body: body, params: params, options: options, method_name: method_name - end - - def make_http_request *args, **kwargs - @call_count += 1 - - @requests << @block&.call(*args, **kwargs) - - @response - end - - def endpoint - "endpoint.example.com" - end - - def universe_domain - "example.com" - end - - def stub_logger - nil - end - - def logger - nil - end - end - - def test_list_orders - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_orders_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_orders_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_orders_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_orders parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_orders ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_orders(::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_orders_client_stub.call_count - end - end - end - - def test_get_order - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_order({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_order name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_order ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_order({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_order(::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_order_client_stub.call_count - end - end - end - - def test_create_order - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - order_id = "hello world" - order = {} - request_id = "hello world" - - create_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_order parent: parent, order_id: order_id, order: order, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_order_client_stub.call_count - end - end - end - - def test_update_order - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - update_mask = {} - order = {} - request_id = "hello world" - - update_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, update_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.update_order({ update_mask: update_mask, order: order, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.update_order update_mask: update_mask, order: order, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.update_order ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.update_order({ update_mask: update_mask, order: order, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.update_order(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, update_order_client_stub.call_count - end - end - end - - def test_delete_order - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - force = true - - delete_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, delete_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.delete_order({ name: name, request_id: request_id, force: force }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.delete_order name: name, request_id: request_id, force: force do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.delete_order ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.delete_order({ name: name, request_id: request_id, force: force }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.delete_order(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, delete_order_client_stub.call_count - end - end - end - - def test_submit_order - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - type = :TYPE_UNSPECIFIED - - submit_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_submit_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, submit_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.submit_order({ name: name, request_id: request_id, type: type }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.submit_order name: name, request_id: request_id, type: type do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.submit_order ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.submit_order({ name: name, request_id: request_id, type: type }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.submit_order(::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, submit_order_client_stub.call_count - end - end - end - - def test_cancel_order - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - cancel_order_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_cancel_order_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, cancel_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.cancel_order({ name: name, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.cancel_order name: name, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.cancel_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.cancel_order({ name: name, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.cancel_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, cancel_order_client_stub.call_count - end - end - end - - def test_list_sites - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_sites_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_sites_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_sites_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_sites parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_sites ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_sites(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_sites_client_stub.call_count - end - end - end - - def test_get_site - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_site_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_site({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_site name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_site ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_site({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_site(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_site_client_stub.call_count - end - end - end - - def test_create_site - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - site_id = "hello world" - site = {} - request_id = "hello world" - - create_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_site_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_site parent: parent, site_id: site_id, site: site, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_site ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_site(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_site_client_stub.call_count - end - end - end - - def test_update_site - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - update_mask = {} - site = {} - request_id = "hello world" - - update_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_site_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, update_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.update_site({ update_mask: update_mask, site: site, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.update_site update_mask: update_mask, site: site, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.update_site ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.update_site({ update_mask: update_mask, site: site, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.update_site(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, update_site_client_stub.call_count - end - end - end - - def test_delete_site - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_site_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_site_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, delete_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.delete_site({ name: name, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.delete_site name: name, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.delete_site ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.delete_site({ name: name, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.delete_site(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, delete_site_client_stub.call_count - end - end - end - - def test_list_hardware_groups - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_hardware_groups_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_hardware_groups_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_hardware_groups_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_hardware_groups parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_hardware_groups ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_hardware_groups(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_hardware_groups_client_stub.call_count - end - end - end - - def test_get_hardware_group - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_hardware_group_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_hardware_group({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_hardware_group name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_hardware_group({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_hardware_group_client_stub.call_count - end - end - end - - def test_create_hardware_group - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - hardware_group_id = "hello world" - hardware_group = {} - request_id = "hello world" - - create_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_hardware_group_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_hardware_group parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_hardware_group_client_stub.call_count - end - end - end - - def test_update_hardware_group - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - update_mask = {} - hardware_group = {} - request_id = "hello world" - - update_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_hardware_group_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, update_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.update_hardware_group update_mask: update_mask, hardware_group: hardware_group, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.update_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.update_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, update_hardware_group_client_stub.call_count - end - end - end - - def test_delete_hardware_group - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_hardware_group_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_hardware_group_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, delete_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.delete_hardware_group({ name: name, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.delete_hardware_group name: name, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.delete_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.delete_hardware_group({ name: name, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.delete_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, delete_hardware_group_client_stub.call_count - end - end - end - - def test_list_hardware - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_hardware_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_hardware parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_hardware_client_stub.call_count - end - end - end - - def test_get_hardware - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_hardware_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_hardware({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_hardware name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_hardware({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_hardware_client_stub.call_count - end - end - end - - def test_create_hardware - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - hardware_id = "hello world" - hardware = {} - - create_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_hardware_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_hardware parent: parent, hardware_id: hardware_id, hardware: hardware do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_hardware_client_stub.call_count - end - end - end - - def test_update_hardware - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - update_mask = {} - hardware = {} - request_id = "hello world" - - update_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_hardware_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, update_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.update_hardware update_mask: update_mask, hardware: hardware, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.update_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.update_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, update_hardware_client_stub.call_count - end - end - end - - def test_delete_hardware - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_hardware_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_hardware_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, delete_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.delete_hardware({ name: name, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.delete_hardware name: name, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.delete_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.delete_hardware({ name: name, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.delete_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, delete_hardware_client_stub.call_count - end - end - end - - def test_list_comments - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_comments_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_comments_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_comments_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_comments parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_comments ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_comments(::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_comments_client_stub.call_count - end - end - end - - def test_get_comment - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_comment_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_comment({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_comment name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_comment({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_comment_client_stub.call_count - end - end - end - - def test_create_comment - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - comment_id = "hello world" - comment = {} - request_id = "hello world" - - create_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_comment_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_comment parent: parent, comment_id: comment_id, comment: comment, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_comment_client_stub.call_count - end - end - end - - def test_record_action_on_comment - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - action_type = :ACTION_TYPE_UNSPECIFIED - - record_action_on_comment_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_record_action_on_comment_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, record_action_on_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.record_action_on_comment({ name: name, action_type: action_type }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.record_action_on_comment name: name, action_type: action_type do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.record_action_on_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.record_action_on_comment({ name: name, action_type: action_type }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.record_action_on_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, record_action_on_comment_client_stub.call_count - end - end - end - - def test_list_change_log_entries - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_change_log_entries_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_change_log_entries_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_change_log_entries_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_change_log_entries parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_change_log_entries ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_change_log_entries(::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_change_log_entries_client_stub.call_count - end - end - end - - def test_get_change_log_entry - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_change_log_entry_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_change_log_entry_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_change_log_entry_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_change_log_entry({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_change_log_entry name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_change_log_entry ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_change_log_entry({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_change_log_entry(::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_change_log_entry_client_stub.call_count - end - end - end - - def test_list_skus - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_skus_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_skus_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_skus_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_skus parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_skus ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_skus(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_skus_client_stub.call_count - end - end - end - - def test_get_sku - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_sku_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_sku_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_sku_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_sku({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_sku name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_sku ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_sku({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_sku(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_sku_client_stub.call_count - end - end - end - - def test_list_zones - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_zones_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_list_zones_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, list_zones_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.list_zones parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.list_zones ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.list_zones(::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, list_zones_client_stub.call_count - end - end - end - - def test_get_zone - # Create test objects. - client_result = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_get_zone_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, get_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.get_zone({ name: name }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.get_zone name: name do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.get_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.get_zone({ name: name }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.get_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, get_zone_client_stub.call_count - end - end - end - - def test_create_zone - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - zone_id = "hello world" - zone = {} - request_id = "hello world" - - create_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_create_zone_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, create_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.create_zone parent: parent, zone_id: zone_id, zone: zone, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.create_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.create_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, create_zone_client_stub.call_count - end - end - end - - def test_update_zone - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - update_mask = {} - zone = {} - request_id = "hello world" - - update_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_update_zone_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, update_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.update_zone update_mask: update_mask, zone: zone, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.update_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.update_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, update_zone_client_stub.call_count - end - end - end - - def test_delete_zone - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_zone_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_delete_zone_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, delete_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.delete_zone({ name: name, request_id: request_id }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.delete_zone name: name, request_id: request_id do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.delete_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.delete_zone({ name: name, request_id: request_id }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.delete_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, delete_zone_client_stub.call_count - end - end - end - - def test_signal_zone_state - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - state_signal = :STATE_SIGNAL_UNSPECIFIED - provisioning_state_signal = :PROVISIONING_STATE_SIGNAL_UNSPECIFIED - step = "hello world" - details = "hello world" - - signal_zone_state_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_signal_zone_state_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, signal_zone_state_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.signal_zone_state name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.signal_zone_state ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.signal_zone_state(::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, signal_zone_state_client_stub.call_count - end - end - end - - def test_request_order_date_change - # Create test objects. - client_result = ::Google::Longrunning::Operation.new - http_response = OpenStruct.new body: client_result.to_json - - call_options = {} - - # Create request parameters for a unary method. - name = "hello world" - requested_date = {} - - request_order_date_change_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:, method_name:| - assert options.metadata.key? :"x-goog-api-client" - assert options.metadata[:"x-goog-api-client"].include? "rest" - refute options.metadata[:"x-goog-api-client"].include? "grpc" - end - - ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::ServiceStub.stub :transcode_request_order_date_change_request, ["", "", {}] do - Gapic::Rest::ClientStub.stub :new, request_order_date_change_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = :dummy_value - end - - # Use hash object - client.request_order_date_change({ name: name, requested_date: requested_date }) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use named arguments - client.request_order_date_change name: name, requested_date: requested_date do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object - client.request_order_date_change ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use hash object with options - client.request_order_date_change({ name: name, requested_date: requested_date }, call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Use protobuf object with options - client.request_order_date_change(::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date), call_options) do |_result, response| - assert_equal http_response, response.underlying_op - end - - # Verify method calls - assert_equal 5, request_order_date_change_client_stub.call_count - end - end - end - - def test_configure - credentials_token = :dummy_value - - client = block_config = config = nil - dummy_stub = ClientStub.new nil - Gapic::Rest::ClientStub.stub :new, dummy_stub do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client.new do |config| - config.credentials = credentials_token - end - end - - config = client.configure do |c| - block_config = c - end - - assert_same block_config, config - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Rest::Client::Configuration, config - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb deleted file mode 100644 index 112185b2e09a..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management_test.rb +++ /dev/null @@ -1,2554 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "helper" - -require "gapic/grpc/service_stub" - -require "google/cloud/gdchardwaremanagement/v1alpha/service_pb" -require "google/cloud/gdc_hardware_management/v1alpha/gdc_hardware_management" - -class ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::ClientTest < Minitest::Test - class ClientStub - attr_accessor :call_rpc_count, :requests - - def initialize response, operation, &block - @response = response - @operation = operation - @block = block - @call_rpc_count = 0 - @requests = [] - end - - def call_rpc *args, **kwargs - @call_rpc_count += 1 - - @requests << @block&.call(*args, **kwargs) - - catch :response do - yield @response, @operation if block_given? - @response - end - end - - def endpoint - "endpoint.example.com" - end - - def universe_domain - "example.com" - end - - def stub_logger - nil - end - - def logger - nil - end - end - - def test_list_orders - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_orders_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_orders, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_orders_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_orders parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_orders ::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_orders({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_orders(::Google::Cloud::GDCHardwareManagement::V1alpha::ListOrdersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_orders_client_stub.call_rpc_count - end - end - - def test_get_order - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Order.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_order({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_order name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_order ::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_order({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_order(::Google::Cloud::GDCHardwareManagement::V1alpha::GetOrderRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_order_client_stub.call_rpc_count - end - end - - def test_create_order - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - order_id = "hello world" - order = {} - request_id = "hello world" - - create_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["order_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Order), request["order"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_order parent: parent, order_id: order_id, order: order, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_order({ parent: parent, order_id: order_id, order: order, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateOrderRequest.new(parent: parent, order_id: order_id, order: order, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_order_client_stub.call_rpc_count - end - end - - def test_update_order - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - update_mask = {} - order = {} - request_id = "hello world" - - update_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :update_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest, request - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Order), request["order"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, update_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.update_order({ update_mask: update_mask, order: order, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.update_order update_mask: update_mask, order: order, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.update_order ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.update_order({ update_mask: update_mask, order: order, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.update_order(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateOrderRequest.new(update_mask: update_mask, order: order, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, update_order_client_stub.call_rpc_count - end - end - - def test_delete_order - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - force = true - - delete_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - assert_equal true, request["force"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_order({ name: name, request_id: request_id, force: force }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_order name: name, request_id: request_id, force: force do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_order ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_order({ name: name, request_id: request_id, force: force }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_order(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteOrderRequest.new(name: name, request_id: request_id, force: force), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_order_client_stub.call_rpc_count - end - end - - def test_submit_order - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - type = :TYPE_UNSPECIFIED - - submit_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :submit_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - assert_equal :TYPE_UNSPECIFIED, request["type"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, submit_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.submit_order({ name: name, request_id: request_id, type: type }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.submit_order name: name, request_id: request_id, type: type do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.submit_order ::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.submit_order({ name: name, request_id: request_id, type: type }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.submit_order(::Google::Cloud::GDCHardwareManagement::V1alpha::SubmitOrderRequest.new(name: name, request_id: request_id, type: type), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, submit_order_client_stub.call_rpc_count - end - end - - def test_cancel_order - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - cancel_order_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :cancel_order, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, cancel_order_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.cancel_order({ name: name, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.cancel_order name: name, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.cancel_order ::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.cancel_order({ name: name, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.cancel_order(::Google::Cloud::GDCHardwareManagement::V1alpha::CancelOrderRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, cancel_order_client_stub.call_rpc_count - end - end - - def test_list_sites - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_sites_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_sites, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_sites_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_sites parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_sites ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_sites({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_sites(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSitesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_sites_client_stub.call_rpc_count - end - end - - def test_get_site - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Site.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_site, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_site({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_site name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_site ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_site({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_site(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSiteRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_site_client_stub.call_rpc_count - end - end - - def test_create_site - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - site_id = "hello world" - site = {} - request_id = "hello world" - - create_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_site, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["site_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Site), request["site"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_site parent: parent, site_id: site_id, site: site, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_site ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_site({ parent: parent, site_id: site_id, site: site, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_site(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateSiteRequest.new(parent: parent, site_id: site_id, site: site, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_site_client_stub.call_rpc_count - end - end - - def test_update_site - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - update_mask = {} - site = {} - request_id = "hello world" - - update_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :update_site, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest, request - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Site), request["site"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, update_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.update_site({ update_mask: update_mask, site: site, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.update_site update_mask: update_mask, site: site, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.update_site ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.update_site({ update_mask: update_mask, site: site, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.update_site(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateSiteRequest.new(update_mask: update_mask, site: site, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, update_site_client_stub.call_rpc_count - end - end - - def test_delete_site - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_site_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_site, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_site_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_site({ name: name, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_site name: name, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_site ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_site({ name: name, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_site(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteSiteRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_site_client_stub.call_rpc_count - end - end - - def test_list_hardware_groups - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_hardware_groups_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_hardware_groups, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_hardware_groups_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_hardware_groups parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_hardware_groups ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_hardware_groups({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_hardware_groups(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareGroupsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_hardware_groups_client_stub.call_rpc_count - end - end - - def test_get_hardware_group - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_hardware_group, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_hardware_group({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_hardware_group name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_hardware_group({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareGroupRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_hardware_group_client_stub.call_rpc_count - end - end - - def test_create_hardware_group - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - hardware_group_id = "hello world" - hardware_group = {} - request_id = "hello world" - - create_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_hardware_group, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["hardware_group_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup), request["hardware_group"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_hardware_group parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_hardware_group({ parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareGroupRequest.new(parent: parent, hardware_group_id: hardware_group_id, hardware_group: hardware_group, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_hardware_group_client_stub.call_rpc_count - end - end - - def test_update_hardware_group - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - update_mask = {} - hardware_group = {} - request_id = "hello world" - - update_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :update_hardware_group, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest, request - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::HardwareGroup), request["hardware_group"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, update_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.update_hardware_group update_mask: update_mask, hardware_group: hardware_group, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.update_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.update_hardware_group({ update_mask: update_mask, hardware_group: hardware_group, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.update_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareGroupRequest.new(update_mask: update_mask, hardware_group: hardware_group, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, update_hardware_group_client_stub.call_rpc_count - end - end - - def test_delete_hardware_group - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_hardware_group_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_hardware_group, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_hardware_group_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_hardware_group({ name: name, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_hardware_group name: name, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_hardware_group ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_hardware_group({ name: name, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_hardware_group(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareGroupRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_hardware_group_client_stub.call_rpc_count - end - end - - def test_list_hardware - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_hardware, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_hardware parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_hardware({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::ListHardwareRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_hardware_client_stub.call_rpc_count - end - end - - def test_get_hardware - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_hardware, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_hardware({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_hardware name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_hardware({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::GetHardwareRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_hardware_client_stub.call_rpc_count - end - end - - def test_create_hardware - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - hardware_id = "hello world" - hardware = {} - - create_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_hardware, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["hardware_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware), request["hardware"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_hardware parent: parent, hardware_id: hardware_id, hardware: hardware do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_hardware({ parent: parent, hardware_id: hardware_id, hardware: hardware }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateHardwareRequest.new(parent: parent, hardware_id: hardware_id, hardware: hardware), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_hardware_client_stub.call_rpc_count - end - end - - def test_update_hardware - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - update_mask = {} - hardware = {} - request_id = "hello world" - - update_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :update_hardware, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest, request - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Hardware), request["hardware"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, update_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.update_hardware update_mask: update_mask, hardware: hardware, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.update_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.update_hardware({ update_mask: update_mask, hardware: hardware, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.update_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateHardwareRequest.new(update_mask: update_mask, hardware: hardware, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, update_hardware_client_stub.call_rpc_count - end - end - - def test_delete_hardware - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_hardware_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_hardware, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_hardware_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_hardware({ name: name, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_hardware name: name, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_hardware ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_hardware({ name: name, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_hardware(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteHardwareRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_hardware_client_stub.call_rpc_count - end - end - - def test_list_comments - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_comments_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_comments, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_comments_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_comments parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_comments ::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_comments({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_comments(::Google::Cloud::GDCHardwareManagement::V1alpha::ListCommentsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_comments_client_stub.call_rpc_count - end - end - - def test_get_comment - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_comment, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_comment({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_comment name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_comment({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::GetCommentRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_comment_client_stub.call_rpc_count - end - end - - def test_create_comment - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - comment_id = "hello world" - comment = {} - request_id = "hello world" - - create_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_comment, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["comment_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment), request["comment"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_comment parent: parent, comment_id: comment_id, comment: comment, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_comment({ parent: parent, comment_id: comment_id, comment: comment, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateCommentRequest.new(parent: parent, comment_id: comment_id, comment: comment, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_comment_client_stub.call_rpc_count - end - end - - def test_record_action_on_comment - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Comment.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - action_type = :ACTION_TYPE_UNSPECIFIED - - record_action_on_comment_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :record_action_on_comment, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest, request - assert_equal "hello world", request["name"] - assert_equal :ACTION_TYPE_UNSPECIFIED, request["action_type"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, record_action_on_comment_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.record_action_on_comment({ name: name, action_type: action_type }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.record_action_on_comment name: name, action_type: action_type do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.record_action_on_comment ::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.record_action_on_comment({ name: name, action_type: action_type }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.record_action_on_comment(::Google::Cloud::GDCHardwareManagement::V1alpha::RecordActionOnCommentRequest.new(name: name, action_type: action_type), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, record_action_on_comment_client_stub.call_rpc_count - end - end - - def test_list_change_log_entries - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_change_log_entries_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_change_log_entries, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_change_log_entries_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_change_log_entries parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_change_log_entries ::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_change_log_entries({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_change_log_entries(::Google::Cloud::GDCHardwareManagement::V1alpha::ListChangeLogEntriesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_change_log_entries_client_stub.call_rpc_count - end - end - - def test_get_change_log_entry - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ChangeLogEntry.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_change_log_entry_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_change_log_entry, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_change_log_entry_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_change_log_entry({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_change_log_entry name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_change_log_entry ::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_change_log_entry({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_change_log_entry(::Google::Cloud::GDCHardwareManagement::V1alpha::GetChangeLogEntryRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_change_log_entry_client_stub.call_rpc_count - end - end - - def test_list_skus - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_skus_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_skus, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_skus_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_skus parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_skus ::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_skus({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_skus(::Google::Cloud::GDCHardwareManagement::V1alpha::ListSkusRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_skus_client_stub.call_rpc_count - end - end - - def test_get_sku - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Sku.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_sku_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_sku, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_sku_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_sku({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_sku name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_sku ::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_sku({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_sku(::Google::Cloud::GDCHardwareManagement::V1alpha::GetSkuRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_sku_client_stub.call_rpc_count - end - end - - def test_list_zones - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesResponse.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - page_size = 42 - page_token = "hello world" - filter = "hello world" - order_by = "hello world" - - list_zones_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :list_zones, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest, request - assert_equal "hello world", request["parent"] - assert_equal 42, request["page_size"] - assert_equal "hello world", request["page_token"] - assert_equal "hello world", request["filter"] - assert_equal "hello world", request["order_by"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, list_zones_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.list_zones parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.list_zones ::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.list_zones({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.list_zones(::Google::Cloud::GDCHardwareManagement::V1alpha::ListZonesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), grpc_options) do |response, operation| - assert_kind_of Gapic::PagedEnumerable, response - assert_equal grpc_response, response.response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, list_zones_client_stub.call_rpc_count - end - end - - def test_get_zone - # Create GRPC objects. - grpc_response = ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - - get_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :get_zone, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest, request - assert_equal "hello world", request["name"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, get_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.get_zone({ name: name }) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use named arguments - client.get_zone name: name do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.get_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.get_zone({ name: name }, grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.get_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::GetZoneRequest.new(name: name), grpc_options) do |response, operation| - assert_equal grpc_response, response - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, get_zone_client_stub.call_rpc_count - end - end - - def test_create_zone - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - parent = "hello world" - zone_id = "hello world" - zone = {} - request_id = "hello world" - - create_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :create_zone, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest, request - assert_equal "hello world", request["parent"] - assert_equal "hello world", request["zone_id"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone), request["zone"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, create_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.create_zone parent: parent, zone_id: zone_id, zone: zone, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.create_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.create_zone({ parent: parent, zone_id: zone_id, zone: zone, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.create_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::CreateZoneRequest.new(parent: parent, zone_id: zone_id, zone: zone, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, create_zone_client_stub.call_rpc_count - end - end - - def test_update_zone - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - update_mask = {} - zone = {} - request_id = "hello world" - - update_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :update_zone, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest, request - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Protobuf::FieldMask), request["update_mask"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Cloud::GDCHardwareManagement::V1alpha::Zone), request["zone"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, update_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.update_zone update_mask: update_mask, zone: zone, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.update_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.update_zone({ update_mask: update_mask, zone: zone, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.update_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::UpdateZoneRequest.new(update_mask: update_mask, zone: zone, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, update_zone_client_stub.call_rpc_count - end - end - - def test_delete_zone - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - - delete_zone_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :delete_zone, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, delete_zone_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.delete_zone({ name: name, request_id: request_id }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.delete_zone name: name, request_id: request_id do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.delete_zone ::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.delete_zone({ name: name, request_id: request_id }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.delete_zone(::Google::Cloud::GDCHardwareManagement::V1alpha::DeleteZoneRequest.new(name: name, request_id: request_id), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, delete_zone_client_stub.call_rpc_count - end - end - - def test_signal_zone_state - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - request_id = "hello world" - state_signal = :STATE_SIGNAL_UNSPECIFIED - provisioning_state_signal = :PROVISIONING_STATE_SIGNAL_UNSPECIFIED - step = "hello world" - details = "hello world" - - signal_zone_state_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :signal_zone_state, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest, request - assert_equal "hello world", request["name"] - assert_equal "hello world", request["request_id"] - assert_equal :STATE_SIGNAL_UNSPECIFIED, request["state_signal"] - assert_equal :PROVISIONING_STATE_SIGNAL_UNSPECIFIED, request["provisioning_state_signal"] - assert_equal "hello world", request["step"] - assert_equal "hello world", request["details"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, signal_zone_state_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.signal_zone_state name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.signal_zone_state ::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.signal_zone_state({ name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.signal_zone_state(::Google::Cloud::GDCHardwareManagement::V1alpha::SignalZoneStateRequest.new(name: name, request_id: request_id, state_signal: state_signal, provisioning_state_signal: provisioning_state_signal, step: step, details: details), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, signal_zone_state_client_stub.call_rpc_count - end - end - - def test_request_order_date_change - # Create GRPC objects. - grpc_response = ::Google::Longrunning::Operation.new - grpc_operation = GRPC::ActiveCall::Operation.new nil - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - grpc_options = {} - - # Create request parameters for a unary method. - name = "hello world" - requested_date = {} - - request_order_date_change_client_stub = ClientStub.new grpc_response, grpc_operation do |name, request, options:| - assert_equal :request_order_date_change, name - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest, request - assert_equal "hello world", request["name"] - assert_equal Gapic::Protobuf.coerce({}, to: ::Google::Type::Date), request["requested_date"] - refute_nil options - end - - Gapic::ServiceStub.stub :new, request_order_date_change_client_stub do - # Create client - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - - # Use hash object - client.request_order_date_change({ name: name, requested_date: requested_date }) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use named arguments - client.request_order_date_change name: name, requested_date: requested_date do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object - client.request_order_date_change ::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use hash object with options - client.request_order_date_change({ name: name, requested_date: requested_date }, grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Use protobuf object with options - client.request_order_date_change(::Google::Cloud::GDCHardwareManagement::V1alpha::RequestOrderDateChangeRequest.new(name: name, requested_date: requested_date), grpc_options) do |response, operation| - assert_kind_of Gapic::Operation, response - assert_equal grpc_response, response.grpc_op - assert_equal grpc_operation, operation - end - - # Verify method calls - assert_equal 5, request_order_date_change_client_stub.call_rpc_count - end - end - - def test_configure - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - - client = block_config = config = nil - dummy_stub = ClientStub.new nil, nil - Gapic::ServiceStub.stub :new, dummy_stub do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - end - - config = client.configure do |c| - block_config = c - end - - assert_same block_config, config - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client::Configuration, config - end - - def test_credentials - key = OpenSSL::PKey::RSA.new 2048 - cred_json = { - "private_key" => key.to_pem, - "client_email" => "app@developer.gserviceaccount.com", - "type" => "service_account" - } - key_file = StringIO.new cred_json.to_json - creds = Google::Auth::ServiceAccountCredentials.make_creds({ json_key_io: key_file }) - - dummy_stub = ClientStub.new nil, nil - Gapic::ServiceStub.stub :new, dummy_stub do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = creds - end - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client, client - assert_equal creds, client.configure.credentials - end - end - - def test_operations_client - grpc_channel = GRPC::Core::Channel.new "localhost:8888", nil, :this_channel_is_insecure - - client = nil - dummy_stub = ClientStub.new nil, nil - Gapic::ServiceStub.stub :new, dummy_stub do - client = ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Client.new do |config| - config.credentials = grpc_channel - end - end - - assert_kind_of ::Google::Cloud::GDCHardwareManagement::V1alpha::GDCHardwareManagement::Operations, client.operations_client - end -end diff --git a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb b/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb deleted file mode 100644 index f0e715458fa2..000000000000 --- a/owl-bot-staging/google-cloud-gdc_hardware_management-v1alpha/test/helper.rb +++ /dev/null @@ -1,25 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Auto-generated by gapic-generator-ruby. DO NOT EDIT! - -require "minitest/autorun" -require "minitest/focus" -require "minitest/rg" - -require "grpc" - -require "ostruct"