Module: Google::Cloud::Dataproc::V1::SessionController::Paths
- Extended by:
- Paths
- Included in:
- Client, Paths, Rest::Client
- Defined in:
- lib/google/cloud/dataproc/v1/session_controller/paths.rb
Overview
Path helper methods for the SessionController API.
Instance Method Summary collapse
-
#crypto_key_path(project:, location:, key_ring:, crypto_key:) ⇒ ::String
Create a fully-qualified CryptoKey resource string.
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
-
#service_path(project:, location:, service:) ⇒ ::String
Create a fully-qualified Service resource string.
-
#session_path(project:, location:, session:) ⇒ ::String
Create a fully-qualified Session resource string.
-
#session_template_path(project:, location:, template:) ⇒ ::String
Create a fully-qualified SessionTemplate resource string.
Instance Method Details
#crypto_key_path(project:, location:, key_ring:, crypto_key:) ⇒ ::String
Create a fully-qualified CryptoKey resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}
40 41 42 43 44 45 46 |
# File 'lib/google/cloud/dataproc/v1/session_controller/paths.rb', line 40 def crypto_key_path project:, location:, key_ring:, crypto_key: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "key_ring cannot contain /" if key_ring.to_s.include? "/" "projects/#{project}/locations/#{location}/keyRings/#{key_ring}/cryptoKeys/#{crypto_key}" 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}
59 60 61 62 63 |
# File 'lib/google/cloud/dataproc/v1/session_controller/paths.rb', line 59 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |
#service_path(project:, location:, service:) ⇒ ::String
Create a fully-qualified Service resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/services/{service}
77 78 79 80 81 82 |
# File 'lib/google/cloud/dataproc/v1/session_controller/paths.rb', line 77 def service_path project:, location:, service: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/services/#{service}" end |
#session_path(project:, location:, session:) ⇒ ::String
Create a fully-qualified Session resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/sessions/{session}
96 97 98 99 100 101 |
# File 'lib/google/cloud/dataproc/v1/session_controller/paths.rb', line 96 def session_path project:, location:, session: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/sessions/#{session}" end |
#session_template_path(project:, location:, template:) ⇒ ::String
Create a fully-qualified SessionTemplate resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/sessionTemplates/{template}
115 116 117 118 119 120 |
# File 'lib/google/cloud/dataproc/v1/session_controller/paths.rb', line 115 def session_template_path project:, location:, template: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/sessionTemplates/#{template}" end |