google-cloud-compute-v1 3.12.0 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (402) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +5 -17
  3. data/lib/google/cloud/compute/v1/accelerator_types/rest.rb +2 -0
  4. data/lib/google/cloud/compute/v1/accelerator_types.rb +2 -0
  5. data/lib/google/cloud/compute/v1/addresses/rest/client.rb +5 -17
  6. data/lib/google/cloud/compute/v1/addresses/rest.rb +2 -0
  7. data/lib/google/cloud/compute/v1/addresses.rb +2 -0
  8. data/lib/google/cloud/compute/v1/advice/rest/client.rb +3 -1
  9. data/lib/google/cloud/compute/v1/advice/rest.rb +2 -0
  10. data/lib/google/cloud/compute/v1/advice.rb +2 -0
  11. data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +5 -17
  12. data/lib/google/cloud/compute/v1/autoscalers/rest.rb +2 -0
  13. data/lib/google/cloud/compute/v1/autoscalers.rb +2 -0
  14. data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +6 -25
  15. data/lib/google/cloud/compute/v1/backend_buckets/rest.rb +2 -0
  16. data/lib/google/cloud/compute/v1/backend_buckets.rb +2 -0
  17. data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +6 -25
  18. data/lib/google/cloud/compute/v1/backend_services/rest.rb +2 -0
  19. data/lib/google/cloud/compute/v1/backend_services.rb +2 -0
  20. data/lib/google/cloud/compute/v1/compute_pb.rb +19 -1
  21. data/lib/google/cloud/compute/v1/cross_site_networks/rest/client.rb +4 -9
  22. data/lib/google/cloud/compute/v1/cross_site_networks/rest.rb +2 -0
  23. data/lib/google/cloud/compute/v1/cross_site_networks.rb +2 -0
  24. data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +5 -17
  25. data/lib/google/cloud/compute/v1/disk_types/rest.rb +2 -0
  26. data/lib/google/cloud/compute/v1/disk_types.rb +2 -0
  27. data/lib/google/cloud/compute/v1/disks/rest/client.rb +5 -17
  28. data/lib/google/cloud/compute/v1/disks/rest.rb +2 -0
  29. data/lib/google/cloud/compute/v1/disks.rb +2 -0
  30. data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +4 -9
  31. data/lib/google/cloud/compute/v1/external_vpn_gateways/rest.rb +2 -0
  32. data/lib/google/cloud/compute/v1/external_vpn_gateways.rb +2 -0
  33. data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +4 -9
  34. data/lib/google/cloud/compute/v1/firewall_policies/rest.rb +2 -0
  35. data/lib/google/cloud/compute/v1/firewall_policies.rb +2 -0
  36. data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +4 -9
  37. data/lib/google/cloud/compute/v1/firewalls/rest.rb +2 -0
  38. data/lib/google/cloud/compute/v1/firewalls.rb +2 -0
  39. data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +5 -17
  40. data/lib/google/cloud/compute/v1/forwarding_rules/rest.rb +2 -0
  41. data/lib/google/cloud/compute/v1/forwarding_rules.rb +2 -0
  42. data/lib/google/cloud/compute/v1/future_reservations/rest/client.rb +5 -17
  43. data/lib/google/cloud/compute/v1/future_reservations/rest.rb +2 -0
  44. data/lib/google/cloud/compute/v1/future_reservations.rb +2 -0
  45. data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +4 -9
  46. data/lib/google/cloud/compute/v1/global_addresses/rest.rb +2 -0
  47. data/lib/google/cloud/compute/v1/global_addresses.rb +2 -0
  48. data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +4 -9
  49. data/lib/google/cloud/compute/v1/global_forwarding_rules/rest.rb +2 -0
  50. data/lib/google/cloud/compute/v1/global_forwarding_rules.rb +2 -0
  51. data/lib/google/cloud/compute/v1/global_frontend_settings_service/credentials.rb +52 -0
  52. data/lib/google/cloud/compute/v1/global_frontend_settings_service/rest/client.rb +524 -0
  53. data/lib/google/cloud/compute/v1/global_frontend_settings_service/rest/service_stub.rb +204 -0
  54. data/lib/google/cloud/compute/v1/global_frontend_settings_service/rest.rb +53 -0
  55. data/lib/google/cloud/compute/v1/global_frontend_settings_service.rb +49 -0
  56. data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +5 -17
  57. data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest.rb +2 -0
  58. data/lib/google/cloud/compute/v1/global_network_endpoint_groups.rb +2 -0
  59. data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +5 -17
  60. data/lib/google/cloud/compute/v1/global_operations/rest.rb +2 -0
  61. data/lib/google/cloud/compute/v1/global_operations.rb +2 -0
  62. data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +4 -9
  63. data/lib/google/cloud/compute/v1/global_organization_operations/rest.rb +2 -0
  64. data/lib/google/cloud/compute/v1/global_organization_operations.rb +2 -0
  65. data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +4 -9
  66. data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest.rb +2 -0
  67. data/lib/google/cloud/compute/v1/global_public_delegated_prefixes.rb +2 -0
  68. data/lib/google/cloud/compute/v1/global_vm_extension_policies/rest/client.rb +5 -17
  69. data/lib/google/cloud/compute/v1/global_vm_extension_policies/rest.rb +2 -0
  70. data/lib/google/cloud/compute/v1/global_vm_extension_policies.rb +2 -0
  71. data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +5 -17
  72. data/lib/google/cloud/compute/v1/health_checks/rest.rb +2 -0
  73. data/lib/google/cloud/compute/v1/health_checks.rb +2 -0
  74. data/lib/google/cloud/compute/v1/hosts/rest/client.rb +4 -9
  75. data/lib/google/cloud/compute/v1/hosts/rest.rb +2 -0
  76. data/lib/google/cloud/compute/v1/hosts.rb +2 -0
  77. data/lib/google/cloud/compute/v1/image_family_views/rest/client.rb +3 -1
  78. data/lib/google/cloud/compute/v1/image_family_views/rest.rb +2 -0
  79. data/lib/google/cloud/compute/v1/image_family_views.rb +2 -0
  80. data/lib/google/cloud/compute/v1/image_views/credentials.rb +53 -0
  81. data/lib/google/cloud/compute/v1/image_views/rest/client.rb +612 -0
  82. data/lib/google/cloud/compute/v1/image_views/rest/service_stub.rb +206 -0
  83. data/lib/google/cloud/compute/v1/image_views/rest.rb +53 -0
  84. data/lib/google/cloud/compute/v1/image_views.rb +49 -0
  85. data/lib/google/cloud/compute/v1/images/rest/client.rb +4 -9
  86. data/lib/google/cloud/compute/v1/images/rest.rb +2 -0
  87. data/lib/google/cloud/compute/v1/images.rb +2 -0
  88. data/lib/google/cloud/compute/v1/instance_group_manager_resize_requests/rest/client.rb +4 -9
  89. data/lib/google/cloud/compute/v1/instance_group_manager_resize_requests/rest.rb +2 -0
  90. data/lib/google/cloud/compute/v1/instance_group_manager_resize_requests.rb +2 -0
  91. data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +8 -41
  92. data/lib/google/cloud/compute/v1/instance_group_managers/rest.rb +2 -0
  93. data/lib/google/cloud/compute/v1/instance_group_managers.rb +2 -0
  94. data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +6 -25
  95. data/lib/google/cloud/compute/v1/instance_groups/rest.rb +2 -0
  96. data/lib/google/cloud/compute/v1/instance_groups.rb +2 -0
  97. data/lib/google/cloud/compute/v1/instance_settings_service/rest/client.rb +3 -1
  98. data/lib/google/cloud/compute/v1/instance_settings_service/rest.rb +2 -0
  99. data/lib/google/cloud/compute/v1/instance_settings_service.rb +2 -0
  100. data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +5 -17
  101. data/lib/google/cloud/compute/v1/instance_templates/rest.rb +2 -0
  102. data/lib/google/cloud/compute/v1/instance_templates.rb +2 -0
  103. data/lib/google/cloud/compute/v1/instances/rest/client.rb +6 -25
  104. data/lib/google/cloud/compute/v1/instances/rest.rb +2 -0
  105. data/lib/google/cloud/compute/v1/instances.rb +2 -0
  106. data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest/client.rb +4 -9
  107. data/lib/google/cloud/compute/v1/instant_snapshot_groups/rest.rb +2 -0
  108. data/lib/google/cloud/compute/v1/instant_snapshot_groups.rb +2 -0
  109. data/lib/google/cloud/compute/v1/instant_snapshots/rest/client.rb +5 -17
  110. data/lib/google/cloud/compute/v1/instant_snapshots/rest.rb +2 -0
  111. data/lib/google/cloud/compute/v1/instant_snapshots.rb +2 -0
  112. data/lib/google/cloud/compute/v1/interconnect_attachment_groups/rest/client.rb +4 -9
  113. data/lib/google/cloud/compute/v1/interconnect_attachment_groups/rest.rb +2 -0
  114. data/lib/google/cloud/compute/v1/interconnect_attachment_groups.rb +2 -0
  115. data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +5 -17
  116. data/lib/google/cloud/compute/v1/interconnect_attachments/rest.rb +2 -0
  117. data/lib/google/cloud/compute/v1/interconnect_attachments.rb +2 -0
  118. data/lib/google/cloud/compute/v1/interconnect_groups/rest/client.rb +4 -9
  119. data/lib/google/cloud/compute/v1/interconnect_groups/rest.rb +2 -0
  120. data/lib/google/cloud/compute/v1/interconnect_groups.rb +2 -0
  121. data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +4 -9
  122. data/lib/google/cloud/compute/v1/interconnect_locations/rest.rb +2 -0
  123. data/lib/google/cloud/compute/v1/interconnect_locations.rb +2 -0
  124. data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest/client.rb +4 -9
  125. data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest.rb +2 -0
  126. data/lib/google/cloud/compute/v1/interconnect_remote_locations.rb +2 -0
  127. data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +118 -9
  128. data/lib/google/cloud/compute/v1/interconnects/rest/service_stub.rb +63 -0
  129. data/lib/google/cloud/compute/v1/interconnects/rest.rb +2 -0
  130. data/lib/google/cloud/compute/v1/interconnects.rb +2 -0
  131. data/lib/google/cloud/compute/v1/license_codes/rest/client.rb +3 -1
  132. data/lib/google/cloud/compute/v1/license_codes/rest.rb +2 -0
  133. data/lib/google/cloud/compute/v1/license_codes.rb +2 -0
  134. data/lib/google/cloud/compute/v1/licenses/rest/client.rb +4 -9
  135. data/lib/google/cloud/compute/v1/licenses/rest.rb +2 -0
  136. data/lib/google/cloud/compute/v1/licenses.rb +2 -0
  137. data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +4 -9
  138. data/lib/google/cloud/compute/v1/machine_images/rest.rb +2 -0
  139. data/lib/google/cloud/compute/v1/machine_images.rb +2 -0
  140. data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +5 -17
  141. data/lib/google/cloud/compute/v1/machine_types/rest.rb +2 -0
  142. data/lib/google/cloud/compute/v1/machine_types.rb +2 -0
  143. data/lib/google/cloud/compute/v1/managed_rulesets/credentials.rb +53 -0
  144. data/lib/google/cloud/compute/v1/managed_rulesets/rest/client.rb +606 -0
  145. data/lib/google/cloud/compute/v1/managed_rulesets/rest/service_stub.rb +204 -0
  146. data/lib/google/cloud/compute/v1/managed_rulesets/rest.rb +53 -0
  147. data/lib/google/cloud/compute/v1/managed_rulesets.rb +49 -0
  148. data/lib/google/cloud/compute/v1/network_attachments/rest/client.rb +5 -17
  149. data/lib/google/cloud/compute/v1/network_attachments/rest.rb +2 -0
  150. data/lib/google/cloud/compute/v1/network_attachments.rb +2 -0
  151. data/lib/google/cloud/compute/v1/network_edge_security_services/rest/client.rb +4 -9
  152. data/lib/google/cloud/compute/v1/network_edge_security_services/rest.rb +2 -0
  153. data/lib/google/cloud/compute/v1/network_edge_security_services.rb +2 -0
  154. data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +6 -25
  155. data/lib/google/cloud/compute/v1/network_endpoint_groups/rest.rb +2 -0
  156. data/lib/google/cloud/compute/v1/network_endpoint_groups.rb +2 -0
  157. data/lib/google/cloud/compute/v1/network_firewall_policies/rest/client.rb +5 -17
  158. data/lib/google/cloud/compute/v1/network_firewall_policies/rest.rb +2 -0
  159. data/lib/google/cloud/compute/v1/network_firewall_policies.rb +2 -0
  160. data/lib/google/cloud/compute/v1/network_profiles/rest/client.rb +4 -9
  161. data/lib/google/cloud/compute/v1/network_profiles/rest.rb +2 -0
  162. data/lib/google/cloud/compute/v1/network_profiles.rb +2 -0
  163. data/lib/google/cloud/compute/v1/networks/rest/client.rb +5 -17
  164. data/lib/google/cloud/compute/v1/networks/rest.rb +2 -0
  165. data/lib/google/cloud/compute/v1/networks.rb +2 -0
  166. data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +6 -25
  167. data/lib/google/cloud/compute/v1/node_groups/rest.rb +2 -0
  168. data/lib/google/cloud/compute/v1/node_groups.rb +2 -0
  169. data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +5 -17
  170. data/lib/google/cloud/compute/v1/node_templates/rest.rb +2 -0
  171. data/lib/google/cloud/compute/v1/node_templates.rb +2 -0
  172. data/lib/google/cloud/compute/v1/node_types/rest/client.rb +5 -17
  173. data/lib/google/cloud/compute/v1/node_types/rest.rb +2 -0
  174. data/lib/google/cloud/compute/v1/node_types.rb +2 -0
  175. data/lib/google/cloud/compute/v1/organization_security_policies/rest/client.rb +5 -17
  176. data/lib/google/cloud/compute/v1/organization_security_policies/rest.rb +2 -0
  177. data/lib/google/cloud/compute/v1/organization_security_policies.rb +2 -0
  178. data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +5 -17
  179. data/lib/google/cloud/compute/v1/packet_mirrorings/rest.rb +2 -0
  180. data/lib/google/cloud/compute/v1/packet_mirrorings.rb +2 -0
  181. data/lib/google/cloud/compute/v1/preview_features/rest/client.rb +4 -9
  182. data/lib/google/cloud/compute/v1/preview_features/rest.rb +2 -0
  183. data/lib/google/cloud/compute/v1/preview_features.rb +2 -0
  184. data/lib/google/cloud/compute/v1/project_views/rest/client.rb +3 -1
  185. data/lib/google/cloud/compute/v1/project_views/rest.rb +2 -0
  186. data/lib/google/cloud/compute/v1/project_views.rb +2 -0
  187. data/lib/google/cloud/compute/v1/projects/rest/client.rb +5 -17
  188. data/lib/google/cloud/compute/v1/projects/rest.rb +2 -0
  189. data/lib/google/cloud/compute/v1/projects.rb +2 -0
  190. data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +4 -9
  191. data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest.rb +2 -0
  192. data/lib/google/cloud/compute/v1/public_advertised_prefixes.rb +2 -0
  193. data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +5 -17
  194. data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest.rb +2 -0
  195. data/lib/google/cloud/compute/v1/public_delegated_prefixes.rb +2 -0
  196. data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +4 -9
  197. data/lib/google/cloud/compute/v1/region_autoscalers/rest.rb +2 -0
  198. data/lib/google/cloud/compute/v1/region_autoscalers.rb +2 -0
  199. data/lib/google/cloud/compute/v1/region_backend_buckets/rest/client.rb +5 -17
  200. data/lib/google/cloud/compute/v1/region_backend_buckets/rest.rb +2 -0
  201. data/lib/google/cloud/compute/v1/region_backend_buckets.rb +2 -0
  202. data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +5 -17
  203. data/lib/google/cloud/compute/v1/region_backend_services/rest.rb +2 -0
  204. data/lib/google/cloud/compute/v1/region_backend_services.rb +2 -0
  205. data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +5 -17
  206. data/lib/google/cloud/compute/v1/region_commitments/rest.rb +2 -0
  207. data/lib/google/cloud/compute/v1/region_commitments.rb +2 -0
  208. data/lib/google/cloud/compute/v1/region_composite_health_checks/rest/client.rb +5 -17
  209. data/lib/google/cloud/compute/v1/region_composite_health_checks/rest.rb +2 -0
  210. data/lib/google/cloud/compute/v1/region_composite_health_checks.rb +2 -0
  211. data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +4 -9
  212. data/lib/google/cloud/compute/v1/region_disk_types/rest.rb +2 -0
  213. data/lib/google/cloud/compute/v1/region_disk_types.rb +2 -0
  214. data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +4 -9
  215. data/lib/google/cloud/compute/v1/region_disks/rest.rb +2 -0
  216. data/lib/google/cloud/compute/v1/region_disks.rb +2 -0
  217. data/lib/google/cloud/compute/v1/region_health_aggregation_policies/rest/client.rb +5 -17
  218. data/lib/google/cloud/compute/v1/region_health_aggregation_policies/rest.rb +2 -0
  219. data/lib/google/cloud/compute/v1/region_health_aggregation_policies.rb +2 -0
  220. data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +5 -17
  221. data/lib/google/cloud/compute/v1/region_health_check_services/rest.rb +2 -0
  222. data/lib/google/cloud/compute/v1/region_health_check_services.rb +2 -0
  223. data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +4 -9
  224. data/lib/google/cloud/compute/v1/region_health_checks/rest.rb +2 -0
  225. data/lib/google/cloud/compute/v1/region_health_checks.rb +2 -0
  226. data/lib/google/cloud/compute/v1/region_health_sources/rest/client.rb +5 -17
  227. data/lib/google/cloud/compute/v1/region_health_sources/rest.rb +2 -0
  228. data/lib/google/cloud/compute/v1/region_health_sources.rb +2 -0
  229. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest/client.rb +4 -9
  230. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests/rest.rb +2 -0
  231. data/lib/google/cloud/compute/v1/region_instance_group_manager_resize_requests.rb +2 -0
  232. data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +7 -33
  233. data/lib/google/cloud/compute/v1/region_instance_group_managers/rest.rb +2 -0
  234. data/lib/google/cloud/compute/v1/region_instance_group_managers.rb +2 -0
  235. data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +5 -17
  236. data/lib/google/cloud/compute/v1/region_instance_groups/rest.rb +2 -0
  237. data/lib/google/cloud/compute/v1/region_instance_groups.rb +2 -0
  238. data/lib/google/cloud/compute/v1/region_instance_templates/rest/client.rb +4 -9
  239. data/lib/google/cloud/compute/v1/region_instance_templates/rest.rb +2 -0
  240. data/lib/google/cloud/compute/v1/region_instance_templates.rb +2 -0
  241. data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +3 -1
  242. data/lib/google/cloud/compute/v1/region_instances/rest.rb +2 -0
  243. data/lib/google/cloud/compute/v1/region_instances.rb +2 -0
  244. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest/client.rb +4 -9
  245. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups/rest.rb +2 -0
  246. data/lib/google/cloud/compute/v1/region_instant_snapshot_groups.rb +2 -0
  247. data/lib/google/cloud/compute/v1/region_instant_snapshots/rest/client.rb +4 -9
  248. data/lib/google/cloud/compute/v1/region_instant_snapshots/rest.rb +2 -0
  249. data/lib/google/cloud/compute/v1/region_instant_snapshots.rb +2 -0
  250. data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +5 -17
  251. data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest.rb +2 -0
  252. data/lib/google/cloud/compute/v1/region_network_endpoint_groups.rb +2 -0
  253. data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/client.rb +126 -10
  254. data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/service_stub.rb +64 -0
  255. data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest.rb +2 -0
  256. data/lib/google/cloud/compute/v1/region_network_firewall_policies.rb +2 -0
  257. data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +5 -17
  258. data/lib/google/cloud/compute/v1/region_notification_endpoints/rest.rb +2 -0
  259. data/lib/google/cloud/compute/v1/region_notification_endpoints.rb +2 -0
  260. data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +4 -9
  261. data/lib/google/cloud/compute/v1/region_operations/rest.rb +2 -0
  262. data/lib/google/cloud/compute/v1/region_operations.rb +2 -0
  263. data/lib/google/cloud/compute/v1/region_security_policies/rest/client.rb +4 -9
  264. data/lib/google/cloud/compute/v1/region_security_policies/rest.rb +2 -0
  265. data/lib/google/cloud/compute/v1/region_security_policies.rb +2 -0
  266. data/lib/google/cloud/compute/v1/region_snapshot_settings/rest/client.rb +3 -1
  267. data/lib/google/cloud/compute/v1/region_snapshot_settings/rest.rb +2 -0
  268. data/lib/google/cloud/compute/v1/region_snapshot_settings.rb +2 -0
  269. data/lib/google/cloud/compute/v1/region_snapshots/rest/client.rb +4 -9
  270. data/lib/google/cloud/compute/v1/region_snapshots/rest.rb +2 -0
  271. data/lib/google/cloud/compute/v1/region_snapshots.rb +2 -0
  272. data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +4 -9
  273. data/lib/google/cloud/compute/v1/region_ssl_certificates/rest.rb +2 -0
  274. data/lib/google/cloud/compute/v1/region_ssl_certificates.rb +2 -0
  275. data/lib/google/cloud/compute/v1/region_ssl_policies/rest/client.rb +5 -17
  276. data/lib/google/cloud/compute/v1/region_ssl_policies/rest.rb +2 -0
  277. data/lib/google/cloud/compute/v1/region_ssl_policies.rb +2 -0
  278. data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +4 -9
  279. data/lib/google/cloud/compute/v1/region_target_http_proxies/rest.rb +2 -0
  280. data/lib/google/cloud/compute/v1/region_target_http_proxies.rb +2 -0
  281. data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +4 -9
  282. data/lib/google/cloud/compute/v1/region_target_https_proxies/rest.rb +2 -0
  283. data/lib/google/cloud/compute/v1/region_target_https_proxies.rb +2 -0
  284. data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/client.rb +4 -9
  285. data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest.rb +2 -0
  286. data/lib/google/cloud/compute/v1/region_target_tcp_proxies.rb +2 -0
  287. data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +4 -9
  288. data/lib/google/cloud/compute/v1/region_url_maps/rest.rb +2 -0
  289. data/lib/google/cloud/compute/v1/region_url_maps.rb +2 -0
  290. data/lib/google/cloud/compute/v1/region_zones/rest/client.rb +4 -9
  291. data/lib/google/cloud/compute/v1/region_zones/rest.rb +2 -0
  292. data/lib/google/cloud/compute/v1/region_zones.rb +2 -0
  293. data/lib/google/cloud/compute/v1/regions/rest/client.rb +4 -9
  294. data/lib/google/cloud/compute/v1/regions/rest.rb +2 -0
  295. data/lib/google/cloud/compute/v1/regions.rb +2 -0
  296. data/lib/google/cloud/compute/v1/reliability_risks/rest/client.rb +4 -9
  297. data/lib/google/cloud/compute/v1/reliability_risks/rest.rb +2 -0
  298. data/lib/google/cloud/compute/v1/reliability_risks.rb +2 -0
  299. data/lib/google/cloud/compute/v1/reservation_blocks/rest/client.rb +4 -9
  300. data/lib/google/cloud/compute/v1/reservation_blocks/rest.rb +2 -0
  301. data/lib/google/cloud/compute/v1/reservation_blocks.rb +2 -0
  302. data/lib/google/cloud/compute/v1/reservation_slots/rest/client.rb +4 -9
  303. data/lib/google/cloud/compute/v1/reservation_slots/rest.rb +2 -0
  304. data/lib/google/cloud/compute/v1/reservation_slots.rb +2 -0
  305. data/lib/google/cloud/compute/v1/reservation_sub_blocks/rest/client.rb +4 -9
  306. data/lib/google/cloud/compute/v1/reservation_sub_blocks/rest.rb +2 -0
  307. data/lib/google/cloud/compute/v1/reservation_sub_blocks.rb +2 -0
  308. data/lib/google/cloud/compute/v1/reservations/rest/client.rb +5 -17
  309. data/lib/google/cloud/compute/v1/reservations/rest.rb +2 -0
  310. data/lib/google/cloud/compute/v1/reservations.rb +2 -0
  311. data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +5 -17
  312. data/lib/google/cloud/compute/v1/resource_policies/rest.rb +2 -0
  313. data/lib/google/cloud/compute/v1/resource_policies.rb +2 -0
  314. data/lib/google/cloud/compute/v1/rest.rb +3 -0
  315. data/lib/google/cloud/compute/v1/rollout_plans/rest/client.rb +4 -9
  316. data/lib/google/cloud/compute/v1/rollout_plans/rest.rb +2 -0
  317. data/lib/google/cloud/compute/v1/rollout_plans.rb +2 -0
  318. data/lib/google/cloud/compute/v1/rollouts/rest/client.rb +4 -9
  319. data/lib/google/cloud/compute/v1/rollouts/rest.rb +2 -0
  320. data/lib/google/cloud/compute/v1/rollouts.rb +2 -0
  321. data/lib/google/cloud/compute/v1/routers/rest/client.rb +9 -49
  322. data/lib/google/cloud/compute/v1/routers/rest.rb +2 -0
  323. data/lib/google/cloud/compute/v1/routers.rb +2 -0
  324. data/lib/google/cloud/compute/v1/routes/rest/client.rb +4 -9
  325. data/lib/google/cloud/compute/v1/routes/rest.rb +2 -0
  326. data/lib/google/cloud/compute/v1/routes.rb +2 -0
  327. data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +6 -25
  328. data/lib/google/cloud/compute/v1/security_policies/rest.rb +2 -0
  329. data/lib/google/cloud/compute/v1/security_policies.rb +2 -0
  330. data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +5 -17
  331. data/lib/google/cloud/compute/v1/service_attachments/rest.rb +2 -0
  332. data/lib/google/cloud/compute/v1/service_attachments.rb +2 -0
  333. data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/client.rb +3 -1
  334. data/lib/google/cloud/compute/v1/snapshot_settings_service/rest.rb +2 -0
  335. data/lib/google/cloud/compute/v1/snapshot_settings_service.rb +2 -0
  336. data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +4 -9
  337. data/lib/google/cloud/compute/v1/snapshots/rest.rb +2 -0
  338. data/lib/google/cloud/compute/v1/snapshots.rb +2 -0
  339. data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +5 -17
  340. data/lib/google/cloud/compute/v1/ssl_certificates/rest.rb +2 -0
  341. data/lib/google/cloud/compute/v1/ssl_certificates.rb +2 -0
  342. data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +6 -25
  343. data/lib/google/cloud/compute/v1/ssl_policies/rest.rb +2 -0
  344. data/lib/google/cloud/compute/v1/ssl_policies.rb +2 -0
  345. data/lib/google/cloud/compute/v1/storage_pool_types/rest/client.rb +5 -17
  346. data/lib/google/cloud/compute/v1/storage_pool_types/rest.rb +2 -0
  347. data/lib/google/cloud/compute/v1/storage_pool_types.rb +2 -0
  348. data/lib/google/cloud/compute/v1/storage_pools/rest/client.rb +6 -25
  349. data/lib/google/cloud/compute/v1/storage_pools/rest.rb +2 -0
  350. data/lib/google/cloud/compute/v1/storage_pools.rb +2 -0
  351. data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +6 -25
  352. data/lib/google/cloud/compute/v1/subnetworks/rest.rb +2 -0
  353. data/lib/google/cloud/compute/v1/subnetworks.rb +2 -0
  354. data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +4 -9
  355. data/lib/google/cloud/compute/v1/target_grpc_proxies/rest.rb +2 -0
  356. data/lib/google/cloud/compute/v1/target_grpc_proxies.rb +2 -0
  357. data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +5 -17
  358. data/lib/google/cloud/compute/v1/target_http_proxies/rest.rb +2 -0
  359. data/lib/google/cloud/compute/v1/target_http_proxies.rb +2 -0
  360. data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +5 -17
  361. data/lib/google/cloud/compute/v1/target_https_proxies/rest.rb +2 -0
  362. data/lib/google/cloud/compute/v1/target_https_proxies.rb +2 -0
  363. data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +5 -17
  364. data/lib/google/cloud/compute/v1/target_instances/rest.rb +2 -0
  365. data/lib/google/cloud/compute/v1/target_instances.rb +2 -0
  366. data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +5 -17
  367. data/lib/google/cloud/compute/v1/target_pools/rest.rb +2 -0
  368. data/lib/google/cloud/compute/v1/target_pools.rb +2 -0
  369. data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +4 -9
  370. data/lib/google/cloud/compute/v1/target_ssl_proxies/rest.rb +2 -0
  371. data/lib/google/cloud/compute/v1/target_ssl_proxies.rb +2 -0
  372. data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +5 -17
  373. data/lib/google/cloud/compute/v1/target_tcp_proxies/rest.rb +2 -0
  374. data/lib/google/cloud/compute/v1/target_tcp_proxies.rb +2 -0
  375. data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +5 -17
  376. data/lib/google/cloud/compute/v1/target_vpn_gateways/rest.rb +2 -0
  377. data/lib/google/cloud/compute/v1/target_vpn_gateways.rb +2 -0
  378. data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +5 -17
  379. data/lib/google/cloud/compute/v1/url_maps/rest.rb +2 -0
  380. data/lib/google/cloud/compute/v1/url_maps.rb +2 -0
  381. data/lib/google/cloud/compute/v1/version.rb +1 -1
  382. data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +5 -17
  383. data/lib/google/cloud/compute/v1/vpn_gateways/rest.rb +2 -0
  384. data/lib/google/cloud/compute/v1/vpn_gateways.rb +2 -0
  385. data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +5 -17
  386. data/lib/google/cloud/compute/v1/vpn_tunnels/rest.rb +2 -0
  387. data/lib/google/cloud/compute/v1/vpn_tunnels.rb +2 -0
  388. data/lib/google/cloud/compute/v1/wire_groups/rest/client.rb +4 -9
  389. data/lib/google/cloud/compute/v1/wire_groups/rest.rb +2 -0
  390. data/lib/google/cloud/compute/v1/wire_groups.rb +2 -0
  391. data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +4 -9
  392. data/lib/google/cloud/compute/v1/zone_operations/rest.rb +2 -0
  393. data/lib/google/cloud/compute/v1/zone_operations.rb +2 -0
  394. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest/client.rb +4 -9
  395. data/lib/google/cloud/compute/v1/zone_vm_extension_policies/rest.rb +2 -0
  396. data/lib/google/cloud/compute/v1/zone_vm_extension_policies.rb +2 -0
  397. data/lib/google/cloud/compute/v1/zones/rest/client.rb +4 -9
  398. data/lib/google/cloud/compute/v1/zones/rest.rb +2 -0
  399. data/lib/google/cloud/compute/v1/zones.rb +2 -0
  400. data/lib/google/cloud/compute/v1.rb +3 -0
  401. data/proto_docs/google/cloud/compute/v1/compute.rb +566 -1614
  402. metadata +16 -1
@@ -0,0 +1,612 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2026 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "google/cloud/errors"
20
+ require "google/cloud/compute/v1/compute_pb"
21
+ require "google/cloud/compute/v1/image_views/rest/service_stub"
22
+
23
+ module Google
24
+ module Cloud
25
+ module Compute
26
+ module V1
27
+ module ImageViews
28
+ module Rest
29
+ ##
30
+ # REST client for the ImageViews service.
31
+ #
32
+ # The ImageViews API.
33
+ #
34
+ # This client uses ImageViews version 2026-09-01.
35
+ #
36
+ class Client
37
+ # @private
38
+ API_VERSION = "2026-09-01"
39
+
40
+ # @private
41
+ DEFAULT_ENDPOINT_TEMPLATE = "compute.$UNIVERSE_DOMAIN$"
42
+
43
+ # @private
44
+ attr_reader :image_views_stub
45
+
46
+ ##
47
+ # Configure the ImageViews Client class.
48
+ #
49
+ # See {::Google::Cloud::Compute::V1::ImageViews::Rest::Client::Configuration}
50
+ # for a description of the configuration fields.
51
+ #
52
+ # @example
53
+ #
54
+ # # Modify the configuration for all ImageViews clients
55
+ # ::Google::Cloud::Compute::V1::ImageViews::Rest::Client.configure do |config|
56
+ # config.timeout = 10.0
57
+ # end
58
+ #
59
+ # @yield [config] Configure the Client client.
60
+ # @yieldparam config [Client::Configuration]
61
+ #
62
+ # @return [Client::Configuration]
63
+ #
64
+ def self.configure
65
+ @configure ||= begin
66
+ namespace = ["Google", "Cloud", "Compute", "V1"]
67
+ parent_config = while namespace.any?
68
+ parent_name = namespace.join "::"
69
+ parent_const = const_get parent_name
70
+ break parent_const.configure if parent_const.respond_to? :configure
71
+ namespace.pop
72
+ end
73
+ default_config = Client::Configuration.new parent_config
74
+
75
+ default_config.rpcs.get.timeout = 600.0
76
+ default_config.rpcs.get.retry_policy = {
77
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
78
+ }
79
+
80
+ default_config.rpcs.list.timeout = 600.0
81
+ default_config.rpcs.list.retry_policy = {
82
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
83
+ }
84
+
85
+ default_config
86
+ end
87
+ yield @configure if block_given?
88
+ @configure
89
+ end
90
+
91
+ ##
92
+ # Configure the ImageViews Client instance.
93
+ #
94
+ # The configuration is set to the derived mode, meaning that values can be changed,
95
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
96
+ # should be made on {Client.configure}.
97
+ #
98
+ # See {::Google::Cloud::Compute::V1::ImageViews::Rest::Client::Configuration}
99
+ # for a description of the configuration fields.
100
+ #
101
+ # @yield [config] Configure the Client client.
102
+ # @yieldparam config [Client::Configuration]
103
+ #
104
+ # @return [Client::Configuration]
105
+ #
106
+ def configure
107
+ yield @config if block_given?
108
+ @config
109
+ end
110
+
111
+ ##
112
+ # The effective universe domain
113
+ #
114
+ # @return [String]
115
+ #
116
+ def universe_domain
117
+ @image_views_stub.universe_domain
118
+ end
119
+
120
+ ##
121
+ # Create a new ImageViews REST client object.
122
+ #
123
+ # @example
124
+ #
125
+ # # Create a client using the default configuration
126
+ # client = ::Google::Cloud::Compute::V1::ImageViews::Rest::Client.new
127
+ #
128
+ # # Create a client using a custom configuration
129
+ # client = ::Google::Cloud::Compute::V1::ImageViews::Rest::Client.new do |config|
130
+ # config.timeout = 10.0
131
+ # end
132
+ #
133
+ # @yield [config] Configure the ImageViews client.
134
+ # @yieldparam config [Client::Configuration]
135
+ #
136
+ def initialize
137
+ # Create the configuration object
138
+ @config = Configuration.new Client.configure
139
+
140
+ # Yield the configuration if needed
141
+ yield @config if block_given?
142
+
143
+ # Create credentials
144
+ credentials = @config.credentials
145
+ # Use self-signed JWT if the endpoint is unchanged from default,
146
+ # but only if the default endpoint does not have a region prefix.
147
+ enable_self_signed_jwt = @config.endpoint.nil? ||
148
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
149
+ !@config.endpoint.split(".").first.include?("-"))
150
+ credentials ||= Credentials.default scope: @config.scope,
151
+ enable_self_signed_jwt: enable_self_signed_jwt
152
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
153
+ credentials = Credentials.new credentials, scope: @config.scope
154
+ end
155
+
156
+ @quota_project_id = @config.quota_project
157
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
158
+
159
+ @image_views_stub = ::Google::Cloud::Compute::V1::ImageViews::Rest::ServiceStub.new(
160
+ endpoint: @config.endpoint,
161
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
162
+ universe_domain: @config.universe_domain,
163
+ credentials: credentials,
164
+ logger: @config.logger
165
+ )
166
+
167
+ @image_views_stub.logger(stub: true)&.info do |entry|
168
+ entry.set_system_name
169
+ entry.set_service
170
+ entry.message = "Created client for #{entry.service}"
171
+ entry.set_credentials_fields credentials
172
+ entry.set "customEndpoint", @config.endpoint if @config.endpoint
173
+ entry.set "defaultTimeout", @config.timeout if @config.timeout
174
+ entry.set "quotaProject", @quota_project_id if @quota_project_id
175
+ end
176
+ end
177
+
178
+ ##
179
+ # The logger used for request/response debug logging.
180
+ #
181
+ # @return [Logger]
182
+ #
183
+ def logger
184
+ @image_views_stub.logger
185
+ end
186
+
187
+ # Service calls
188
+
189
+ ##
190
+ # Returns the specified global ImageView resource, with a regional
191
+ # context.
192
+ #
193
+ # @overload get(request, options = nil)
194
+ # Pass arguments to `get` via a request object, either of type
195
+ # {::Google::Cloud::Compute::V1::GetImageViewRequest} or an equivalent Hash.
196
+ #
197
+ # @param request [::Google::Cloud::Compute::V1::GetImageViewRequest, ::Hash]
198
+ # A request object representing the call parameters. Required. To specify no
199
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
200
+ # @param options [::Gapic::CallOptions, ::Hash]
201
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
202
+ #
203
+ # @overload get(project: nil, region: nil, resource_id: nil)
204
+ # Pass arguments to `get` via keyword arguments. Note that at
205
+ # least one keyword argument is required. To specify no parameters, or to keep all
206
+ # the default parameter values, pass an empty Hash as a request object (see above).
207
+ #
208
+ # @param project [::String]
209
+ # Required. Project ID for this request.
210
+ # @param region [::String]
211
+ # Required. Name of the region for this request.
212
+ # @param resource_id [::String]
213
+ # Name of the image resource to return.
214
+ # @yield [result, operation] Access the result along with the TransportOperation object
215
+ # @yieldparam result [::Google::Cloud::Compute::V1::ImageView]
216
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
217
+ #
218
+ # @return [::Google::Cloud::Compute::V1::ImageView]
219
+ #
220
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
221
+ #
222
+ # @example Basic example
223
+ # require "google/cloud/compute/v1"
224
+ #
225
+ # # Create a client object. The client can be reused for multiple calls.
226
+ # client = Google::Cloud::Compute::V1::ImageViews::Rest::Client.new
227
+ #
228
+ # # Create a request. To set request fields, pass in keyword arguments.
229
+ # request = Google::Cloud::Compute::V1::GetImageViewRequest.new
230
+ #
231
+ # # Call the get method.
232
+ # result = client.get request
233
+ #
234
+ # # The returned object is of type Google::Cloud::Compute::V1::ImageView.
235
+ # p result
236
+ #
237
+ def get request, options = nil
238
+ raise ::ArgumentError, "request must be provided" if request.nil?
239
+
240
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::GetImageViewRequest
241
+
242
+ # Converts hash and nil to an options object
243
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
244
+
245
+ # Customize the options with defaults
246
+ call_metadata = @config.rpcs.get.metadata.to_h
247
+
248
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
249
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
250
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
251
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
252
+ transports_version_send: [:rest]
253
+
254
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
255
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
256
+
257
+ options.apply_defaults timeout: @config.rpcs.get.timeout,
258
+ metadata: call_metadata,
259
+ retry_policy: @config.rpcs.get.retry_policy
260
+
261
+ options.apply_defaults timeout: @config.timeout,
262
+ metadata: @config.metadata,
263
+ retry_policy: @config.retry_policy
264
+
265
+ @image_views_stub.get request, options do |result, operation|
266
+ yield result, operation if block_given?
267
+ end
268
+ rescue ::Gapic::Rest::Error => e
269
+ raise ::Google::Cloud::Error.from_error(e)
270
+ end
271
+
272
+ ##
273
+ # Returns a list of global ImageView resources, with a regional
274
+ # context.
275
+ #
276
+ # @overload list(request, options = nil)
277
+ # Pass arguments to `list` via a request object, either of type
278
+ # {::Google::Cloud::Compute::V1::ListImageViewsRequest} or an equivalent Hash.
279
+ #
280
+ # @param request [::Google::Cloud::Compute::V1::ListImageViewsRequest, ::Hash]
281
+ # A request object representing the call parameters. Required. To specify no
282
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
283
+ # @param options [::Gapic::CallOptions, ::Hash]
284
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
285
+ #
286
+ # @overload list(filter: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, region: nil)
287
+ # Pass arguments to `list` via keyword arguments. Note that at
288
+ # least one keyword argument is required. To specify no parameters, or to keep all
289
+ # the default parameter values, pass an empty Hash as a request object (see above).
290
+ #
291
+ # @param filter [::String]
292
+ # A filter expression that filters resources listed in the response. Most
293
+ # Compute resources support two types of filter expressions:
294
+ # expressions that support regular expressions and expressions that follow
295
+ # API improvement proposal AIP-160.
296
+ # These two types of filter expressions cannot be mixed in one request.
297
+ #
298
+ # If you want to use AIP-160, your expression must specify the field name, an
299
+ # operator, and the value that you want to use for filtering. The value
300
+ # must be a string, a number, or a boolean. The operator
301
+ # must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`.
302
+ #
303
+ # For example, if you are filtering Compute Engine instances, you can
304
+ # exclude instances named `example-instance` by specifying
305
+ # `name != example-instance`.
306
+ #
307
+ # The `:*` comparison can be used to test whether a key has been defined.
308
+ # For example, to find all objects with `owner` label use:
309
+ # ```
310
+ # labels.owner:*
311
+ # ```
312
+ #
313
+ # You can also filter nested fields. For example, you could specify
314
+ # `scheduling.automaticRestart = false` to include instances only
315
+ # if they are not scheduled for automatic restarts. You can use filtering
316
+ # on nested fields to filter based onresource labels.
317
+ #
318
+ # To filter on multiple expressions, provide each separate expression within
319
+ # parentheses. For example:
320
+ # ```
321
+ # (scheduling.automaticRestart = true)
322
+ # (cpuPlatform = "Intel Skylake")
323
+ # ```
324
+ # By default, each expression is an `AND` expression. However, you
325
+ # can include `AND` and `OR` expressions explicitly.
326
+ # For example:
327
+ # ```
328
+ # (cpuPlatform = "Intel Skylake") OR
329
+ # (cpuPlatform = "Intel Broadwell") AND
330
+ # (scheduling.automaticRestart = true)
331
+ # ```
332
+ #
333
+ # If you want to use a regular expression, use the `eq` (equal) or `ne`
334
+ # (not equal) operator against a single un-parenthesized expression with or
335
+ # without quotes or against multiple parenthesized expressions. Examples:
336
+ #
337
+ # `fieldname eq unquoted literal`
338
+ # `fieldname eq 'single quoted literal'`
339
+ # `fieldname eq "double quoted literal"`
340
+ # `(fieldname1 eq literal) (fieldname2 ne "literal")`
341
+ #
342
+ # The literal value is interpreted as a regular expression using GoogleRE2 library syntax.
343
+ # The literal value must match the entire field.
344
+ #
345
+ # For example, to filter for instances that do not end with name "instance",
346
+ # you would use `name ne .*instance`.
347
+ #
348
+ # You cannot combine constraints on multiple fields using regular
349
+ # expressions.
350
+ # @param max_results [::Integer]
351
+ # The maximum number of results per page that should be returned.
352
+ # If the number of available results is larger than `maxResults`,
353
+ # Compute Engine returns a `nextPageToken` that can be used to get
354
+ # the next page of results in subsequent list requests. Acceptable values are
355
+ # `0` to `500`, inclusive. (Default: `500`)
356
+ # @param order_by [::String]
357
+ # Sorts list results by a certain order. By default, results
358
+ # are returned in alphanumerical order based on the resource name.
359
+ #
360
+ # You can also sort results in descending order based on the creation
361
+ # timestamp using `orderBy="creationTimestamp desc"`. This sorts
362
+ # results based on the `creationTimestamp` field in
363
+ # reverse chronological order (newest result first). Use this to sort
364
+ # resources like operations so that the newest operation is returned first.
365
+ #
366
+ # Currently, only sorting by `name` or
367
+ # `creationTimestamp desc` is supported.
368
+ # @param page_token [::String]
369
+ # Specifies a page token to use. Set `pageToken` to the
370
+ # `nextPageToken` returned by a previous list request to get
371
+ # the next page of results.
372
+ # @param project [::String]
373
+ # Required. Project ID for this request.
374
+ # @param region [::String]
375
+ # Required. Name of the region for this request.
376
+ # @yield [result, operation] Access the result along with the TransportOperation object
377
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::ImageView>]
378
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
379
+ #
380
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Compute::V1::ImageView>]
381
+ #
382
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
383
+ #
384
+ # @example Basic example
385
+ # require "google/cloud/compute/v1"
386
+ #
387
+ # # Create a client object. The client can be reused for multiple calls.
388
+ # client = Google::Cloud::Compute::V1::ImageViews::Rest::Client.new
389
+ #
390
+ # # Create a request. To set request fields, pass in keyword arguments.
391
+ # request = Google::Cloud::Compute::V1::ListImageViewsRequest.new
392
+ #
393
+ # # Call the list method.
394
+ # result = client.list request
395
+ #
396
+ # # The returned object is of type Google::Cloud::Compute::V1::ImageViewsListResponse.
397
+ # p result
398
+ #
399
+ def list request, options = nil
400
+ raise ::ArgumentError, "request must be provided" if request.nil?
401
+
402
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Compute::V1::ListImageViewsRequest
403
+
404
+ # Converts hash and nil to an options object
405
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
406
+
407
+ # Customize the options with defaults
408
+ call_metadata = @config.rpcs.list.metadata.to_h
409
+
410
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
411
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
412
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
413
+ gapic_version: ::Google::Cloud::Compute::V1::VERSION,
414
+ transports_version_send: [:rest]
415
+
416
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
417
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
418
+
419
+ options.apply_defaults timeout: @config.rpcs.list.timeout,
420
+ metadata: call_metadata,
421
+ retry_policy: @config.rpcs.list.retry_policy
422
+
423
+ options.apply_defaults timeout: @config.timeout,
424
+ metadata: @config.metadata,
425
+ retry_policy: @config.retry_policy
426
+
427
+ @image_views_stub.list request, options do |result, operation|
428
+ result = ::Gapic::Rest::PagedEnumerable.new @image_views_stub, :list, "items", request, result, options
429
+ yield result, operation if block_given?
430
+ throw :response, result
431
+ end
432
+ rescue ::Gapic::Rest::Error => e
433
+ raise ::Google::Cloud::Error.from_error(e)
434
+ end
435
+
436
+ ##
437
+ # Configuration class for the ImageViews REST API.
438
+ #
439
+ # This class represents the configuration for ImageViews REST,
440
+ # providing control over timeouts, retry behavior, logging, transport
441
+ # parameters, and other low-level controls. Certain parameters can also be
442
+ # applied individually to specific RPCs. See
443
+ # {::Google::Cloud::Compute::V1::ImageViews::Rest::Client::Configuration::Rpcs}
444
+ # for a list of RPCs that can be configured independently.
445
+ #
446
+ # Configuration can be applied globally to all clients, or to a single client
447
+ # on construction.
448
+ #
449
+ # @example
450
+ #
451
+ # # Modify the global config, setting the timeout for
452
+ # # get to 20 seconds,
453
+ # # and all remaining timeouts to 10 seconds.
454
+ # ::Google::Cloud::Compute::V1::ImageViews::Rest::Client.configure do |config|
455
+ # config.timeout = 10.0
456
+ # config.rpcs.get.timeout = 20.0
457
+ # end
458
+ #
459
+ # # Apply the above configuration only to a new client.
460
+ # client = ::Google::Cloud::Compute::V1::ImageViews::Rest::Client.new do |config|
461
+ # config.timeout = 10.0
462
+ # config.rpcs.get.timeout = 20.0
463
+ # end
464
+ #
465
+ # @!attribute [rw] endpoint
466
+ # A custom service endpoint, as a hostname or hostname:port. The default is
467
+ # nil, indicating to use the default endpoint in the current universe domain.
468
+ # @return [::String,nil]
469
+ # @!attribute [rw] credentials
470
+ # Credentials to send with calls. You may provide any of the following types:
471
+ # * (`String`) The path to a service account key file in JSON format
472
+ # * (`Hash`) A service account key as a Hash
473
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
474
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
475
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
476
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
477
+ # * (`nil`) indicating no credentials
478
+ #
479
+ # Warning: If you accept a credential configuration (JSON file or Hash) from an
480
+ # external source for authentication to Google Cloud, you must validate it before
481
+ # providing it to a Google API client library. Providing an unvalidated credential
482
+ # configuration to Google APIs can compromise the security of your systems and data.
483
+ # For more information, refer to [Validate credential configurations from external
484
+ # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials).
485
+ # @return [::Object]
486
+ # @!attribute [rw] scope
487
+ # The OAuth scopes
488
+ # @return [::Array<::String>]
489
+ # @!attribute [rw] lib_name
490
+ # The library name as recorded in instrumentation and logging
491
+ # @return [::String]
492
+ # @!attribute [rw] lib_version
493
+ # The library version as recorded in instrumentation and logging
494
+ # @return [::String]
495
+ # @!attribute [rw] timeout
496
+ # The call timeout in seconds.
497
+ # @return [::Numeric]
498
+ # @!attribute [rw] metadata
499
+ # Additional headers to be sent with the call.
500
+ # @return [::Hash{::Symbol=>::String}]
501
+ # @!attribute [rw] retry_policy
502
+ # The retry policy. The value is a hash with the following keys:
503
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
504
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
505
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
506
+ # * `:jitter` (*type:* `Numeric`) - The jitter in seconds. Default: 1.0.
507
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
508
+ # trigger a retry.
509
+ # @return [::Hash]
510
+ # @!attribute [rw] quota_project
511
+ # A separate project against which to charge quota.
512
+ # @return [::String]
513
+ # @!attribute [rw] universe_domain
514
+ # The universe domain within which to make requests. This determines the
515
+ # default endpoint URL. The default value of nil uses the environment
516
+ # universe (usually the default "googleapis.com" universe).
517
+ # @return [::String,nil]
518
+ # @!attribute [rw] logger
519
+ # A custom logger to use for request/response debug logging, or the value
520
+ # `:default` (the default) to construct a default logger, or `nil` to
521
+ # explicitly disable logging.
522
+ # @return [::Logger,:default,nil]
523
+ #
524
+ class Configuration
525
+ extend ::Gapic::Config
526
+
527
+ # @private
528
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
529
+ DEFAULT_ENDPOINT = "compute.googleapis.com"
530
+
531
+ config_attr :endpoint, nil, ::String, nil
532
+ config_attr :credentials, nil do |value|
533
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Google::Auth::BaseClient, ::Signet::OAuth2::Client, nil]
534
+ allowed.any? { |klass| klass === value }
535
+ end
536
+ config_attr :scope, nil, ::String, ::Array, nil
537
+ config_attr :lib_name, nil, ::String, nil
538
+ config_attr :lib_version, nil, ::String, nil
539
+ config_attr :timeout, nil, ::Numeric, nil
540
+ config_attr :metadata, nil, ::Hash, nil
541
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
542
+ config_attr :quota_project, nil, ::String, nil
543
+ config_attr :universe_domain, nil, ::String, nil
544
+ config_attr :logger, :default, ::Logger, nil, :default
545
+
546
+ # @private
547
+ def initialize parent_config = nil
548
+ @parent_config = parent_config unless parent_config.nil?
549
+
550
+ yield self if block_given?
551
+ end
552
+
553
+ ##
554
+ # Configurations for individual RPCs
555
+ # @return [Rpcs]
556
+ #
557
+ def rpcs
558
+ @rpcs ||= begin
559
+ parent_rpcs = nil
560
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
561
+ Rpcs.new parent_rpcs
562
+ end
563
+ end
564
+
565
+ ##
566
+ # Configuration RPC class for the ImageViews API.
567
+ #
568
+ # Includes fields providing the configuration for each RPC in this service.
569
+ # Each configuration object is of type `Gapic::Config::Method` and includes
570
+ # the following configuration fields:
571
+ #
572
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
573
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
574
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
575
+ # include the following keys:
576
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
577
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
578
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
579
+ # * `:jitter` (*type:* `Numeric`) - The jitter in seconds. Default: 1.0.
580
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
581
+ # trigger a retry.
582
+ #
583
+ class Rpcs
584
+ ##
585
+ # RPC-specific configuration for `get`
586
+ # @return [::Gapic::Config::Method]
587
+ #
588
+ attr_reader :get
589
+ ##
590
+ # RPC-specific configuration for `list`
591
+ # @return [::Gapic::Config::Method]
592
+ #
593
+ attr_reader :list
594
+
595
+ # @private
596
+ def initialize parent_rpcs = nil
597
+ get_config = parent_rpcs.get if parent_rpcs.respond_to? :get
598
+ @get = ::Gapic::Config::Method.new get_config
599
+ list_config = parent_rpcs.list if parent_rpcs.respond_to? :list
600
+ @list = ::Gapic::Config::Method.new list_config
601
+
602
+ yield self if block_given?
603
+ end
604
+ end
605
+ end
606
+ end
607
+ end
608
+ end
609
+ end
610
+ end
611
+ end
612
+ end