Module: Google::Cloud::StorageTransfer::V1::StorageTransferService::Paths

Extended by:
Paths
Included in:
Client, Paths, Rest::Client
Defined in:
lib/google/cloud/storage_transfer/v1/storage_transfer_service/paths.rb

Overview

Path helper methods for the StorageTransferService API.

Instance Method Summary collapse

Instance Method Details

#agent_pools_path(project_id:, agent_pool_id:) ⇒ ::String

Create a fully-qualified agentPools resource string.

The resource will be in the following format:

projects/{project_id}/agentPools/{agent_pool_id}

Parameters:

  • project_id (String)
  • agent_pool_id (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


38
39
40
41
42
# File 'lib/google/cloud/storage_transfer/v1/storage_transfer_service/paths.rb', line 38

def agent_pools_path project_id:, agent_pool_id:
  raise ::ArgumentError, "project_id cannot contain /" if project_id.to_s.include? "/"

  "projects/#{project_id}/agentPools/#{agent_pool_id}"
end