Module: Google::Cloud::NetworkConnectivity::V1beta::HubService::Paths
- Extended by:
- Paths
- Defined in:
- lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb
Overview
Path helper methods for the HubService API.
Instance Method Summary collapse
-
#gateway_advertised_route_path(project:, location:, spoke:, gateway_advertised_route:) ⇒ ::String
Create a fully-qualified GatewayAdvertisedRoute resource string.
-
#group_path(project:, hub:, group:) ⇒ ::String
Create a fully-qualified Group resource string.
-
#hub_path(project:, hub:) ⇒ ::String
Create a fully-qualified Hub resource string.
-
#hub_route_path(project:, hub:, route_table:, route:) ⇒ ::String
Create a fully-qualified HubRoute resource string.
-
#instance_path(project:, zone:, instance:) ⇒ ::String
Create a fully-qualified Instance resource string.
-
#interconnect_attachment_path(project:, region:, resource_id:) ⇒ ::String
Create a fully-qualified InterconnectAttachment resource string.
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
-
#network_path(project:, resource_id:) ⇒ ::String
Create a fully-qualified Network resource string.
-
#route_table_path(project:, hub:, route_table:) ⇒ ::String
Create a fully-qualified RouteTable resource string.
-
#sac_attachment_path(project:, location:, sac_attachment:) ⇒ ::String
Create a fully-qualified SACAttachment resource string.
-
#spoke_path(project:, location:, spoke:) ⇒ ::String
Create a fully-qualified Spoke resource string.
-
#vpn_tunnel_path(project:, region:, resource_id:) ⇒ ::String
Create a fully-qualified VpnTunnel resource string.
Instance Method Details
#gateway_advertised_route_path(project:, location:, spoke:, gateway_advertised_route:) ⇒ ::String
Create a fully-qualified GatewayAdvertisedRoute resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route}
40 41 42 43 44 45 46 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 40 def gateway_advertised_route_path project:, location:, spoke:, gateway_advertised_route: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "spoke cannot contain /" if spoke.to_s.include? "/" "projects/#{project}/locations/#{location}/spokes/#{spoke}/gatewayAdvertisedRoutes/#{gateway_advertised_route}" end |
#group_path(project:, hub:, group:) ⇒ ::String
Create a fully-qualified Group resource string.
The resource will be in the following format:
projects/{project}/locations/global/hubs/{hub}/groups/{group}
60 61 62 63 64 65 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 60 def group_path project:, hub:, group: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "hub cannot contain /" if hub.to_s.include? "/" "projects/#{project}/locations/global/hubs/#{hub}/groups/#{group}" end |
#hub_path(project:, hub:) ⇒ ::String
Create a fully-qualified Hub resource string.
The resource will be in the following format:
projects/{project}/locations/global/hubs/{hub}
78 79 80 81 82 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 78 def hub_path project:, hub: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/global/hubs/#{hub}" end |
#hub_route_path(project:, hub:, route_table:, route:) ⇒ ::String
Create a fully-qualified HubRoute resource string.
The resource will be in the following format:
projects/{project}/locations/global/hubs/{hub}/routeTables/{route_table}/routes/{route}
97 98 99 100 101 102 103 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 97 def hub_route_path project:, hub:, route_table:, route: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "hub cannot contain /" if hub.to_s.include? "/" raise ::ArgumentError, "route_table cannot contain /" if route_table.to_s.include? "/" "projects/#{project}/locations/global/hubs/#{hub}/routeTables/#{route_table}/routes/#{route}" end |
#instance_path(project:, zone:, instance:) ⇒ ::String
Create a fully-qualified Instance resource string.
The resource will be in the following format:
projects/{project}/zones/{zone}/instances/{instance}
117 118 119 120 121 122 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 117 def instance_path project:, zone:, instance: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "zone cannot contain /" if zone.to_s.include? "/" "projects/#{project}/zones/#{zone}/instances/#{instance}" end |
#interconnect_attachment_path(project:, region:, resource_id:) ⇒ ::String
Create a fully-qualified InterconnectAttachment resource string.
The resource will be in the following format:
projects/{project}/regions/{region}/interconnectAttachments/{resource_id}
136 137 138 139 140 141 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 136 def project:, region:, resource_id: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "region cannot contain /" if region.to_s.include? "/" "projects/#{project}/regions/#{region}/interconnectAttachments/#{resource_id}" end |
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
The resource will be in the following format:
projects/{project}/locations/{location}
154 155 156 157 158 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 154 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |
#network_path(project:, resource_id:) ⇒ ::String
Create a fully-qualified Network resource string.
The resource will be in the following format:
projects/{project}/global/networks/{resource_id}
171 172 173 174 175 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 171 def network_path project:, resource_id: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/global/networks/#{resource_id}" end |
#route_table_path(project:, hub:, route_table:) ⇒ ::String
Create a fully-qualified RouteTable resource string.
The resource will be in the following format:
projects/{project}/locations/global/hubs/{hub}/routeTables/{route_table}
189 190 191 192 193 194 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 189 def route_table_path project:, hub:, route_table: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "hub cannot contain /" if hub.to_s.include? "/" "projects/#{project}/locations/global/hubs/#{hub}/routeTables/#{route_table}" end |
#sac_attachment_path(project:, location:, sac_attachment:) ⇒ ::String
Create a fully-qualified SACAttachment resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
208 209 210 211 212 213 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 208 def project:, location:, sac_attachment: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/sacAttachments/#{}" end |
#spoke_path(project:, location:, spoke:) ⇒ ::String
Create a fully-qualified Spoke resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/spokes/{spoke}
227 228 229 230 231 232 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 227 def spoke_path project:, location:, spoke: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/spokes/#{spoke}" end |
#vpn_tunnel_path(project:, region:, resource_id:) ⇒ ::String
Create a fully-qualified VpnTunnel resource string.
The resource will be in the following format:
projects/{project}/regions/{region}/vpnTunnels/{resource_id}
246 247 248 249 250 251 |
# File 'lib/google/cloud/network_connectivity/v1beta/hub_service/paths.rb', line 246 def vpn_tunnel_path project:, region:, resource_id: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "region cannot contain /" if region.to_s.include? "/" "projects/#{project}/regions/#{region}/vpnTunnels/#{resource_id}" end |