module Google::Cloud::AssuredWorkloads::V1::AssuredWorkloadsService::Paths

Path helper methods for the AssuredWorkloadsService API.

Public Instance Methods

location_path(organization:, location: raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/") click to toggle source

Create a fully-qualified Location resource string.

The resource will be in the following format:

‘organizations/{organization}/locations/{location}`

@param organization [String] @param location [String]

@return [::String]

# File lib/google/cloud/assured_workloads/v1/assured_workloads_service/paths.rb, line 38
def location_path organization:, location:
  raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"

  "organizations/#{organization}/locations/#{location}"
end
workload_path(organization:, location:, workload: raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/") click to toggle source

Create a fully-qualified Workload resource string.

The resource will be in the following format:

‘organizations/{organization}/locations/{location}/workloads/{workload}`

@param organization [String] @param location [String] @param workload [String]

@return [::String]

# File lib/google/cloud/assured_workloads/v1/assured_workloads_service/paths.rb, line 56
def workload_path organization:, location:, workload:
  raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"

  "organizations/#{organization}/locations/#{location}/workloads/#{workload}"
end