Module: Google::Cloud::Bigquery::Migration::V2::MigrationService::Paths
- Extended by:
- Paths
- Included in:
- Client, Paths, Rest::Client
- Defined in:
- lib/google/cloud/bigquery/migration/v2/migration_service/paths.rb
Overview
Path helper methods for the MigrationService API.
Instance Method Summary collapse
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
-
#migration_subtask_path(project:, location:, workflow:, subtask:) ⇒ ::String
Create a fully-qualified MigrationSubtask resource string.
-
#migration_workflow_path(project:, location:, workflow:) ⇒ ::String
Create a fully-qualified MigrationWorkflow 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}
39 40 41 42 43 |
# File 'lib/google/cloud/bigquery/migration/v2/migration_service/paths.rb', line 39 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |
#migration_subtask_path(project:, location:, workflow:, subtask:) ⇒ ::String
Create a fully-qualified MigrationSubtask resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/workflows/{workflow}/subtasks/{subtask}
58 59 60 61 62 63 64 |
# File 'lib/google/cloud/bigquery/migration/v2/migration_service/paths.rb', line 58 def migration_subtask_path project:, location:, workflow:, subtask: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "workflow cannot contain /" if workflow.to_s.include? "/" "projects/#{project}/locations/#{location}/workflows/#{workflow}/subtasks/#{subtask}" end |
#migration_workflow_path(project:, location:, workflow:) ⇒ ::String
Create a fully-qualified MigrationWorkflow resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/workflows/{workflow}
78 79 80 81 82 83 |
# File 'lib/google/cloud/bigquery/migration/v2/migration_service/paths.rb', line 78 def migration_workflow_path project:, location:, workflow: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/workflows/#{workflow}" end |