Module: Google::Cloud::NetworkSecurity::V1::SSERealmService::Paths

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

Overview

Path helper methods for the SSERealmService API.

Instance Method Summary collapse

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}

Parameters:

  • project (String)
  • location (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


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

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

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

#sac_attachment_path(project:, location:, sac_attachment:) ⇒ ::String

Create a fully-qualified SACAttachment resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/sacAttachments/{sac_attachment}

Parameters:

  • project (String)
  • location (String)
  • sac_attachment (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


56
57
58
59
60
61
# File 'lib/google/cloud/network_security/v1/sse_realm_service/paths.rb', line 56

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

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

#sac_realm_path(project:, location:, sac_realm:) ⇒ ::String

Create a fully-qualified SACRealm resource string.

The resource will be in the following format:

projects/{project}/locations/{location}/sacRealms/{sac_realm}

Parameters:

  • project (String)
  • location (String)
  • sac_realm (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


75
76
77
78
79
80
# File 'lib/google/cloud/network_security/v1/sse_realm_service/paths.rb', line 75

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

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