Module: Google::Cloud::Appoptimize::V1beta::AppOptimize::Paths
- Extended by:
- Paths
- Included in:
- Client, Paths, Rest::Client
- Defined in:
- lib/google/cloud/appoptimize/v1beta/app_optimize/paths.rb
Overview
Path helper methods for the AppOptimize API.
Instance Method Summary collapse
-
#application_path(project:, location:, application:) ⇒ ::String
Create a fully-qualified Application resource string.
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
-
#project_path(project:) ⇒ ::String
Create a fully-qualified Project resource string.
-
#report_path(project:, location:, report:) ⇒ ::String
Create a fully-qualified Report resource string.
Instance Method Details
#application_path(project:, location:, application:) ⇒ ::String
Create a fully-qualified Application resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/applications/{application}
39 40 41 42 43 44 |
# File 'lib/google/cloud/appoptimize/v1beta/app_optimize/paths.rb', line 39 def application_path project:, location:, application: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/applications/#{application}" 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}
57 58 59 60 61 |
# File 'lib/google/cloud/appoptimize/v1beta/app_optimize/paths.rb', line 57 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |
#project_path(project:) ⇒ ::String
Create a fully-qualified Project resource string.
The resource will be in the following format:
projects/{project}
73 74 75 |
# File 'lib/google/cloud/appoptimize/v1beta/app_optimize/paths.rb', line 73 def project_path project: "projects/#{project}" end |
#report_path(project:, location:, report:) ⇒ ::String
Create a fully-qualified Report resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/reports/{report}
89 90 91 92 93 94 |
# File 'lib/google/cloud/appoptimize/v1beta/app_optimize/paths.rb', line 89 def report_path project:, location:, report: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/reports/#{report}" end |