Module: Google::Cloud::Ces::V1beta::ToolService::Paths
- Extended by:
- Paths
- Included in:
- Client, Paths, Rest::Client
- Defined in:
- lib/google/cloud/ces/v1beta/tool_service/paths.rb
Overview
Path helper methods for the ToolService API.
Instance Method Summary collapse
-
#app_path(project:, location:, app:) ⇒ ::String
Create a fully-qualified App resource string.
-
#tool_path(project:, location:, app:, tool:) ⇒ ::String
Create a fully-qualified Tool resource string.
-
#toolset_path(project:, location:, app:, toolset:) ⇒ ::String
Create a fully-qualified Toolset resource string.
Instance Method Details
#app_path(project:, location:, app:) ⇒ ::String
Create a fully-qualified App resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/apps/{app}
39 40 41 42 43 44 |
# File 'lib/google/cloud/ces/v1beta/tool_service/paths.rb', line 39 def app_path project:, location:, app: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/apps/#{app}" end |
#tool_path(project:, location:, app:, tool:) ⇒ ::String
Create a fully-qualified Tool resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/apps/{app}/tools/{tool}
59 60 61 62 63 64 65 |
# File 'lib/google/cloud/ces/v1beta/tool_service/paths.rb', line 59 def tool_path project:, location:, app:, tool: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "app cannot contain /" if app.to_s.include? "/" "projects/#{project}/locations/#{location}/apps/#{app}/tools/#{tool}" end |
#toolset_path(project:, location:, app:, toolset:) ⇒ ::String
Create a fully-qualified Toolset resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}
80 81 82 83 84 85 86 |
# File 'lib/google/cloud/ces/v1beta/tool_service/paths.rb', line 80 def toolset_path project:, location:, app:, toolset: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "app cannot contain /" if app.to_s.include? "/" "projects/#{project}/locations/#{location}/apps/#{app}/toolsets/#{toolset}" end |