Module: Google::Cloud::Metastore::V1::DataprocMetastore::Paths
- Extended by:
- Paths
- Defined in:
- lib/google/cloud/metastore/v1/dataproc_metastore/paths.rb
Overview
Path helper methods for the DataprocMetastore API.
Instance Method Summary collapse
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
-
#metadata_import_path(project:, location:, service:, metadata_import:) ⇒ ::String
Create a fully-qualified MetadataImport resource string.
-
#network_path(project:, network:) ⇒ ::String
Create a fully-qualified Network resource string.
-
#service_path(project:, location:, service:) ⇒ ::String
Create a fully-qualified Service resource string.
Instance Method Details
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
The resource will be in the following format:
projects/{project}/locations/{location}
38 39 40 41 42 |
# File 'lib/google/cloud/metastore/v1/dataproc_metastore/paths.rb', line 38 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |
#metadata_import_path(project:, location:, service:, metadata_import:) ⇒ ::String
Create a fully-qualified MetadataImport resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/services/{service}/metadataImports/{metadata_import}
57 58 59 60 61 62 63 |
# File 'lib/google/cloud/metastore/v1/dataproc_metastore/paths.rb', line 57 def project:, location:, service:, metadata_import: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "service cannot contain /" if service.to_s.include? "/" "projects/#{project}/locations/#{location}/services/#{service}/metadataImports/#{}" end |
#network_path(project:, network:) ⇒ ::String
Create a fully-qualified Network resource string.
The resource will be in the following format:
projects/{project}/global/networks/{network}
76 77 78 79 80 |
# File 'lib/google/cloud/metastore/v1/dataproc_metastore/paths.rb', line 76 def network_path project:, network: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/global/networks/#{network}" 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}
94 95 96 97 98 99 |
# File 'lib/google/cloud/metastore/v1/dataproc_metastore/paths.rb', line 94 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 |