Module: Google::Cloud::Connectors::V1::Connectors::Paths

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

Overview

Path helper methods for the Connectors API.

Instance Method Summary collapse

Instance Method Details

#connection_path(project:, location:, connection:) ⇒ ::String

Create a fully-qualified Connection resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/connections/{connection}

Parameters:

  • project (String)
  • location (String)
  • connection (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


39
40
41
42
43
44
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 39

def connection_path project:, location:, connection:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"

  "projects/#{project}/locations/#{location}/connections/#{connection}"
end

#connection_schema_metadata_path(project:, location:, connection:) ⇒ ::String

Create a fully-qualified ConnectionSchemaMetadata resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/connections/{connection}/connectionSchemaMetadata

Parameters:

  • project (String)
  • location (String)
  • connection (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


58
59
60
61
62
63
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 58

def  project:, location:, connection:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"

  "projects/#{project}/locations/#{location}/connections/#{connection}/connectionSchemaMetadata"
end

#connector_path(project:, location:, provider:, connector:) ⇒ ::String

Create a fully-qualified Connector resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/providers/{provider}/connectors/{connector}

Parameters:

  • project (String)
  • location (String)
  • provider (String)
  • connector (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


78
79
80
81
82
83
84
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 78

def connector_path project:, location:, provider:, connector:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
  raise ::ArgumentError, "provider cannot contain /" if provider.to_s.include? "/"

  "projects/#{project}/locations/#{location}/providers/#{provider}/connectors/#{connector}"
end

#connector_version_path(project:, location:, provider:, connector:, version:) ⇒ ::String

Create a fully-qualified ConnectorVersion resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/providers/{provider}/connectors/{connector}/versions/{version}

Parameters:

  • project (String)
  • location (String)
  • provider (String)
  • connector (String)
  • version (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


100
101
102
103
104
105
106
107
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 100

def connector_version_path project:, location:, provider:, connector:, version:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
  raise ::ArgumentError, "provider cannot contain /" if provider.to_s.include? "/"
  raise ::ArgumentError, "connector cannot contain /" if connector.to_s.include? "/"

  "projects/#{project}/locations/#{location}/providers/#{provider}/connectors/#{connector}/versions/#{version}"
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}

Parameters:

  • project (String)
  • location (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


120
121
122
123
124
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 120

def location_path project:, location:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"

  "projects/#{project}/locations/#{location}"
end

#provider_path(project:, location:, provider:) ⇒ ::String

Create a fully-qualified Provider resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/providers/{provider}

Parameters:

  • project (String)
  • location (String)
  • provider (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


138
139
140
141
142
143
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 138

def provider_path project:, location:, provider:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
  raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"

  "projects/#{project}/locations/#{location}/providers/#{provider}"
end

#runtime_config_path(project:, location:) ⇒ ::String

Create a fully-qualified RuntimeConfig resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/runtimeConfig

Parameters:

  • project (String)
  • location (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


156
157
158
159
160
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 156

def runtime_config_path project:, location:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"

  "projects/#{project}/locations/#{location}/runtimeConfig"
end

#settings_path(project:) ⇒ ::String

Create a fully-qualified Settings resource string.

The resource will be in the following format:

projects/{project}/locations/global/settings

Parameters:

  • project (String)

Returns:

  • (::String)


172
173
174
# File 'lib/google/cloud/connectors/v1/connectors/paths.rb', line 172

def settings_path project:
  "projects/#{project}/locations/global/settings"
end